/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * com_distri_articulos_almacen_detalle.java
 *
 * Created on 31/01/2012, 09:56:53 AM
 */

package sie_invdis;


import java.sql.*;
import javax.swing.*;


import javax.swing.JOptionPane;
import javax.swing.JTable;
import javax.swing.JTable.*;
import java.awt.*;
import java.awt.event.*;
import java.util.Date;
import java.util.Calendar;
import java.text.SimpleDateFormat;
import java.text.ParseException;
import java.text.*;
/**
 *
 * @author Michelle
 */
public class com_distri_articulos_almacen_detalle extends javax.swing.JFrame {

     private javax.swing.table.DefaultTableModel jtable_modelo_hojacosto;
     private javax.swing.table.DefaultTableModel jtable_modelo_kardex;
     private javax.swing.table.DefaultTableModel jtable_modelo_familia;
     private javax.swing.table.DefaultTableModel jtable_modelo_detallecompra;
     private javax.swing.table.DefaultTableModel jtable_modelo_detallecompray;
     private int buscamp=0,indexactual=0,opbuscamp=0,yacarguehoja=0,yacarguekardex=0,opcionupdate=0,errorf=0,errorp=0;
     bd_conexion x = new bd_conexion() ;
       //se creaa la variable resultset
     ResultSet rs = null;
     private SimpleDateFormat formateadoresta = new SimpleDateFormat("yyyy-MM-dd");
     private DecimalFormat miforma = new DecimalFormat("#########.##");
     private SimpleDateFormat formateador = new SimpleDateFormat("dd-MM-yyyy");
     private int banderafin=0;
    /** Creates new form com_distri_articulos_almacen_detalle */
    public com_distri_articulos_almacen_detalle() {
        initComponents();
    }
public com_distri_articulos_almacen_detalle(int opcion,String idarticulo) {
    this.iniciar_modelo_hojacosto();
    this.iniciar_modelo_kardex();
    this.loadcombofamilia_alta();
    this.iniciar_modelo_familia();
    this.iniciar_modelo_de_tabla();
    this.iniciar_modelo_de_tablaya();
        initComponents();
        if (opcion==2)
        {
            this.load_combos();
            this.jtf_clavearticulo.setEditable(true);
            this.jtf_codigobarra.setEditable(false);
             try
                {
                    rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_articulos_catalogov2(11,0,'') as (codbarra character varying(16));",variables_global.getconexiongral());
                    while (rs.next())
                        {
                            this.jtf_codigobarra.setText(rs.getString("codbarra"));
                        }
                }
                catch(Exception e)
                    {
                    System.out.println(e.getMessage());
                    }
            this.jtf_clavearticulo.requestFocus();

            opcionupdate=3;
            this.loadcombofamilia_alta();
        }
        if (opcion==1)
        {
            this.loadcombofamilia_alta();
            this.carga_datos_catalogoarticulos_almacen(1, 1, idarticulo);
            this.jtf_descripcion.requestFocus();

            opcionupdate=1;
        }
        jtb_distribucionalta.getColumnModel().getColumn(0).setPreferredWidth(5);//id
        jtb_distribucionalta.getColumnModel().getColumn(1).setPreferredWidth(30);//Codigo
        jtb_distribucionalta.getColumnModel().getColumn(2).setPreferredWidth(10);//Descripcion
    }


 private void iniciar_modelo_hojacosto()
 {
        jtable_modelo_hojacosto=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Tipo</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Id Insumo</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Descripcion</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Unidad</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Cantidad</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Ult. Costo</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Importe Costo</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Observaciones</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Implosion Cant.</b></BODY></html>");
        jtable_modelo_hojacosto.addColumn("<html><BODY><b>Implosion Importe</b></BODY></html>");
}

    private void iniciar_modelo_kardex()
 {
        jtable_modelo_kardex=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_kardex.addColumn("<html><BODY><b>Almacen</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>id movi</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Fecha</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Tipo Mov</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Ref.</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>clie/prov</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Articulo</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Descripcion</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Item</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>U.Sal.</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Costo</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Precio</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Cantidad</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Historial</b></BODY></html>");
        jtable_modelo_kardex.addColumn("<html><BODY><b>Observ.</b></BODY></html>");
}
private void iniciar_modelo_familia()
    {
        jtable_modelo_familia=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_familia.addColumn("<html><b>Id</b></html>");
        jtable_modelo_familia.addColumn("<html><b>Familia</b></html>");
        jtable_modelo_familia.addColumn("<html><b>idext</b></html>");

  }

private void iniciar_modelo_de_tabla()
    {
        jtable_modelo_detallecompra=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_detallecompra.addColumn("<html><b>Clave</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Codigo B</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Descripcion</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Desc Corta</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Item Prov</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Item michelle.</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Un</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Costo</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Precio</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Fam</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Familia</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Idpro</b></html>");
        jtable_modelo_detallecompra.addColumn("<html><b>Proveedoes</b></html>");
    }
private void iniciar_modelo_de_tablaya()
    {
        jtable_modelo_detallecompray=new javax.swing.table.DefaultTableModel();//Creo el modelo
        jtable_modelo_detallecompray.addColumn("<html><b>Clave</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Codigo B</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Descripcion</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Desc Corta</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Item Prov</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Item michelle.</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Un</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Costo</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Precio</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>Fam</b></html>");
        jtable_modelo_detallecompray.addColumn("<html><b>idpro</b></html>");
    }
 private void loadcombotemporada(){
            try
            {
               rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_articulo_temporada() as (id smallint,describe text);",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_temporada.addItem(rs.getString("id")+":"+rs.getString("describe"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
 private void loadcombolineaarticulo(){


            try
            {
               rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_articulo_lineas() as (id smallint,describe text);",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_linea.addItem(rs.getString("id")+":"+rs.getString("describe"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }

 private void loadcombotipo()
 {
          
            try
            {
                rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_articulo_tipos() as (id smallint,describe text);",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_tipoelemento.addItem(rs.getString("id")+":"+rs.getString("describe"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
 private void loadcombostatus()
 {

            try
            {
                rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_articulo_status() as (id smallint,describe text);",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_statusarticulo.addItem(rs.getString("id")+":"+rs.getString("describe"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }

private void loadcombofamilia()
 {
            try
            {
                rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_articulo_familia() as (id character varying(5),describe character varying(40));",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_familia.addItem(rs.getString("id")+":"+rs.getString("describe"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
private void loadcombopersonalmicre()
 {

            try
            {
                rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_personalcreaciones() as (id character varying(16),describe character varying(80));",variables_global.getconexiongral());
               while (rs.next())
                    {
                      this.jcbx_idpersonal.addItem(rs.getString("id")+":"+rs.getString("describe"));
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
private void loadcombofamilia_alta()
 {
        String texto="select * from x1distribucion_terminados_articulo_familia(1,'','','') as (id character varying(5),describe character varying(40),idext text);";
        System.out.println("familia"+texto);
            try
            {
                rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
               while (rs.next())
                    {
                      jtable_modelo_familia.addRow(new Object[]{rs.getString("id"),rs.getString("describe"),rs.getString("idext")});
                    }
             }
            catch(Exception e)
            {
                System.out.println(e.getMessage());
            }
    }
private void load_combos(){
     this.loadcombofamilia();
            this.loadcombolineaarticulo();
            this.loadcombopersonalmicre();
            this.loadcombostatus();
            this.loadcombotemporada();
            this.loadcombotipo();
}
 private void carga_datos_catalogoarticulos_almacen(int rbbuscam,int rbopbuscam,String busqueda)
 {
       String texto="select * from x1distribucion_terminados_articulos_catalogov2("+rbbuscam+","+rbopbuscam+",'"+busqueda+"') as (id character varying(16),codbarra character varying(16),idstatus smallint,statusdescribe text,describearticulo character varying(80),describcorta character varying(20),unsal character varying(3),unent character varying(3),facentruni numeric,uniempaque character varying(12),idtempo smallint,describetemp text,idfamilia character varying(5),familiadescribe character varying(40),controlalma character varying(20),stocminimo numeric,stocmaximo numeric,precio1 numeric,precio2 numeric,precio3 numeric,precio4 numeric,precio5 numeric,ultimocosto numeric,costoprom numeric,pensurtir numeric,tiemposurtido smallint,acumprod numeric,acumimporte numeric,idtipoarticulo smallint,tipodescribe text,fechaprototipo date,fechaautoriza date,fechainiprod date,fechaultimaent date,usuario character varying(20),observacion character varying(255),idprovee character varying(12),descripprovee character varying(60),nombrecreador character varying(80),valor_x character varying(20),valorx_st character varying(20),idpersonal character varying(16),nombrepersonal character varying(80),idlinea smallint,describelinea text,existenciaf numeric,almacenlugar text,existencia numeric)";
       System.out.println(texto);
        banderafin=0;
       DecimalFormat miformat = new DecimalFormat("############.##");
       try
        {
           rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                this.jcbx_statusarticulo.removeAllItems();
                this.jcbx_temporada.removeAllItems();
                this.jcbx_tipoelemento.removeAllItems();
                this.jcbx_familia.removeAllItems();
                this.jcbx_linea.removeAllItems();
                this.jcbx_idpersonal.removeAllItems();

                this.jtf_clavearticulo.setText(rs.getString("id"));
                this.jtf_idarticuloterminado.setText(rs.getString("id"));
                this.jtf_codigobarra.setText(rs.getString("codbarra"));
                this.jcbx_statusarticulo.addItem(rs.getString("idstatus")+":"+rs.getString("statusdescribe"));
                this.jtf_descripcion.setText(rs.getString("describearticulo"));
                this.jtf_descripcorta.setText(rs.getString("describcorta"));
                this.jtf_item.setText(rs.getString("valor_x"));
                this.jtf_unidadsalida.setText(rs.getString("unsal"));
                this.jtf_unidadentrada.setText(rs.getString("unent"));
                this.jtf_factor.setText(rs.getString("facentruni"));
                this.jtf_unidadempake.setText(rs.getString("uniempaque"));
                this.jcbx_temporada.addItem(rs.getString("idtempo")+":"+rs.getString ("describetemp"));
                this.jcbx_tipoelemento.addItem(rs.getString("idtipoarticulo")+":"+rs.getString ("tipodescribe"));
                this.jcbx_familia.addItem(rs.getString("idfamilia")+":"+rs.getString ("familiadescribe"));
                this.jcbx_linea.addItem(rs.getString("idlinea")+":"+rs.getString("describelinea"));
                this.jtf_controlalmacen.setText(rs.getString("controlalma"));
                if(rs.getString("stocminimo")==null)
                    {
                        this.jtf_stockminimo.setText(rs.getString("stocminimo"));
                    }
                else
                    {
                        this.jtf_stockminimo.setText("0");
                    }
                if(rs.getString("stocmaximo")==null)
                    {
                        this.jtf_stockmaximo.setText(rs.getString("stocmaximo"));
                    }
                else
                    {
                        this.jtf_stockmaximo.setText("0");
                    }

                this.jtf_precio1.setText(miformat.format(rs.getFloat("precio1")));
                this.jtf_precio2.setText(miformat.format(rs.getFloat("precio2")));
                this.jtf_precio3.setText(miformat.format(rs.getFloat("precio3")));
                this.jtf_precio4.setText(miformat.format(rs.getFloat("precio4")));
                this.jtf_precio5.setText(miformat.format(rs.getFloat("precio5")));
                this.jtf_ultimocosto.setText(miformat.format(rs.getFloat("ultimocosto")));
                this.jtf_costopromedio.setText(miformat.format(rs.getFloat("costoprom")));
                this.jtf_pendientesurtir.setText(rs.getString("pensurtir"));
                this.jtf_tiemporsurtido.setText(rs.getString("tiemposurtido"));
                this.jtf_acumproducion.setText(rs.getString("acumprod"));
                this.jtf_acumimporte.setText(rs.getString("acumimporte"));
                if (rs.getString("fechaprototipo")!= null)
                        {
                            this.jtf_fechaprototipo.setText(this.fechaeuropea(rs.getString("fechaprototipo")));
                        }
                if (rs.getString("fechaautoriza")!= null)
                        {
                            this.jtf_autoriza.setText(this.fechaeuropea(rs.getString("fechaautoriza")));
                        }
                if (rs.getString("fechainiprod")!= null)
                        {
                            this.jtf_inicioproduccion.setText(this.fechaeuropea(rs.getString("fechainiprod")));
                        }
                if (rs.getString("fechaultimaent")!= null)
                        {
                            this.jtf_fechaultcompra.setText(this.fechaeuropea(rs.getString("fechaultimaent")));
                        }
                this.jtf_idproveedor.setText(rs.getString("idprovee"));
                this.jtf_proveedordescribe.setText(rs.getString("descripprovee"));
                this.jcbx_idpersonal.addItem(rs.getString("idpersonal")+":"+rs.getString("nombrepersonal"));
                this.jtf_nombrecreador.setText(rs.getString("nombrecreador"));
                this.jtf_lugaralmacen.setText(rs.getString("almacenlugar"));
                this.jtf_existencia.setText(rs.getString("existencia"));
                this.jta_observacion.setText(rs.getString("observacion"));
                this.jep_articuloimagen.setText("<img src=\"http://"+variables_global.getHostfotos()+"/"+variables_global.getcarpetaaplicacion()+"/fotos/"+rs.getString ("id")+".JPG\" width=\"402\" height=\"340\" border=\"0\" alt=\"Foto Articulo\"></img>");
                this.setTitle("Sistema Integral:Almacen Detalle Articulo :"+rs.getString("id")+":"+rs.getString("describearticulo"));
                banderafin=1;
                }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }
     if(banderafin==0)
         {
           JOptionPane.showMessageDialog(null,"Clave:"+busqueda+" No Encontrado", "Sistema Integral(Modificar articulo) : Ayuda",1);
         }
       else
         {
            this.loadcombofamilia();
            this.loadcombolineaarticulo();
            this.loadcombopersonalmicre();
            this.loadcombostatus();
            this.loadcombotemporada();
            this.loadcombotipo();
       }
 }
private void carga_datos_catalogoarticulosalta(int rbbuscam,int rbopbuscam,String busqueda)
 {
       Object[] fnewRowdet = new Object[19];
       String texto="select * from x1distribucion_terminados_articulos_catalogov2("+rbbuscam+","+rbopbuscam+",'"+busqueda+"') as (id character varying(16),codbarra character varying(16),idstatus smallint,describearticulo character varying(80),describcorta character varying(20),unent character varying(3),idfamilia character varying(5),controlalma character varying(20),precio5 numeric,ultimocosto numeric,idprovee character varying(12),valor_x character varying(20))";
       System.out.println(texto);
       
       DecimalFormat miformat = new DecimalFormat("############.#####");
       try
        {
           rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {

              
                banderafin=1;
                fnewRowdet[0]=rs.getString("id"); //codigo
                fnewRowdet[1]=rs.getString("codbarra");//descripcion
                fnewRowdet[2]=rs.getString("describearticulo");//desc. corta
                fnewRowdet[3]=rs.getString("describcorta");//desc. corta

                fnewRowdet[4]=rs.getString("valor_x");//item original proveedor
                fnewRowdet[5]=rs.getString("controlalma");//Item Derivado michelle
                fnewRowdet[6]=rs.getString("unent");
                fnewRowdet[7]=miformat.format(rs.getDouble("ultimocosto"));
                fnewRowdet[8]=miformat.format(rs.getDouble("precio5"));
                fnewRowdet[9]=rs.getString("idfamilia");
                fnewRowdet[10]=rs.getString("idprovee");
                jtable_modelo_detallecompray.addRow(fnewRowdet);
                }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }
 }

private void carga_datos_hojacosto(String busqueda)
 {
     String busquedacadena=busqueda.replace("*", ":");
     String busquedaarreglo[]=busquedacadena.split(":"),cantidadb="",busquedab="",costob="";
     int busquedaarreglos=busquedaarreglo.length;
     System.out.println(busquedaarreglos+" cantidad elementos ");
     switch (busquedaarreglos)
        {
            case 1:
                cantidadb="1";
                busquedab=busquedaarreglo[0];
            break;
            case 2:
                cantidadb=busquedaarreglo[0];
                busquedab=busquedaarreglo[1];
            break;
            case 3:
                cantidadb=busquedaarreglo[0];
                busquedab=busquedaarreglo[1];
                costob=busquedaarreglo[2];
            break;
        }
     System.out.println(busquedaarreglos+" "+cantidadb+" "+busquedab+" "+costob);
     DecimalFormat miformat = new DecimalFormat("############.##");
       Object[] fnewRow = new Object[10];
       String texto="select * from x1distribucion_insumos_articulos_catalogo(1,1,'"+busquedab.toUpperCase().trim()+"',1) as (id character varying(16),cod character varying(16), idstatus smallint, descristatus character varying(40), describinsumo character varying(80), itemprovee character varying(16), unisal character varying(3), unient character varying(3), facentunidad numeric, uniempaque character varying(12), tipoelemento smallint, describetipoelemen character varying(40), idfamilia character varying(5),describefamilia character varying(40),idlineainsu character varying(5), describelineainsu character varying(40), controlalmacen character varying(20), stockminimo numeric, stockmaximo numeric,precio1 numeric, precio2 numeric,ultimocosto numeric, costoprome numeric, fechaulticompra date, fechaultimaventa date, idprovee character varying(16), describeprovee character varying(80), impuesto1 numeric, impuesto2 numeric, usuario character varying(20),valor_x_insumo character varying(20), observacion character varying(255),existenciainsu numeric)";
       System.out.println(texto);
       try
        {
           rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                    fnewRow[0]=rs.getString("describetipoelemen");
                    fnewRow[1]=rs.getString("id");
                    fnewRow[2]=rs.getString("describinsumo");
                    fnewRow[3]=rs.getString("unisal");
                    fnewRow[4]=miformat.format(Float.valueOf(cantidadb));
                    if(busquedaarreglos==3)
                        {
                            fnewRow[5]=miformat.format(Float.valueOf(costob));
                            fnewRow[6]=miformat.format(Float.valueOf(costob)*Float.valueOf(cantidadb));
                            fnewRow[8]=miformat.format(Float.valueOf(costob));
                            fnewRow[9]=miformat.format(Float.valueOf(costob)*Float.valueOf(cantidadb));
                        }
                    else
                        {
                            fnewRow[5]=miformat.format(rs.getFloat("precio1"));
                            fnewRow[6]=miformat.format(rs.getFloat("precio1")*Float.valueOf(cantidadb));
                            fnewRow[8]=miformat.format(rs.getFloat("precio1"));
                            fnewRow[9]=miformat.format(rs.getFloat("precio1")*Float.valueOf(cantidadb));
                        }
                    fnewRow[7]=".";
                    
                    jtable_modelo_hojacosto.addRow(fnewRow);
                }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }
 this.calcularimportes();
 }

void carga_datos_kardex(int opcion, String busqueda,String almacen)
 {
       DecimalFormat miformat = new DecimalFormat("###,###,###");
       DecimalFormat miformatd = new DecimalFormat("#########.####");
       while(jtable_modelo_kardex.getRowCount()>0)jtable_modelo_kardex.removeRow(0);
       float historial=0;
       Object[] fnewRow = new Object[15];
       String texto="select * from x1distribucion_terminados_articulos_kardex("+opcion+",'"+busqueda.toUpperCase().trim()+"',"+almacen+") as (folio integer,fechamov date,tipomovinve smallint,tipodescribe text,referenciainve character varying(16),fechareferencia date,clave_clie_prov character varying(12),idarticuloinve character varying(16),cantidadinve numeric,precioinve numeric,costoinve numeric,observainve character varying(80),descripcionarti character varying(80),unidadsal character varying(3),almacen smallint,describealmacen character varying(30),precio5 numeric,item character varying(20))",abrehtml="",cierrahtml="";

       System.out.println(texto);
       try
        {
            rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                if(rs.getFloat("cantidadinve") > 0 )//significa que fue entrada
                    {
                        abrehtml="<html><b>";
                        cierrahtml="</b></html>";
                    }
                else
                    {
                        abrehtml="";
                        cierrahtml="";
                    }
                    historial+=rs.getFloat("cantidadinve");
                    fnewRow[0]=rs.getString ("almacen")+":"+rs.getString ("describealmacen");
                    fnewRow[1]=rs.getString ("folio");
                    fnewRow[2]=this.fechaeuropea(rs.getString("fechareferencia"));
                    fnewRow[3]=rs.getString ("tipomovinve")+":"+rs.getString("tipodescribe");
                    fnewRow[4]=rs.getString ("referenciainve");
                    fnewRow[5]=rs.getString ("clave_clie_prov");
                    fnewRow[6]=rs.getString ("idarticuloinve");
                    fnewRow[7]=rs.getString ("descripcionarti");
                    fnewRow[8]=rs.getString ("item");
                    fnewRow[9]=rs.getString ("unidadsal");
                    fnewRow[10]=miformatd.format(rs.getFloat("costoinve"));
                    fnewRow[11]=miformatd.format(rs.getFloat("precioinve"));
                    fnewRow[12]=abrehtml+rs.getString ("cantidadinve")+cierrahtml;
                    fnewRow[13]=abrehtml+miformat.format(historial)+cierrahtml;
                    fnewRow[14]=rs.getString ("observainve");
                    jtable_modelo_kardex.addRow(fnewRow);
                }

        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }

 }

private void carga_datos_hojacostover(String busqueda)
 {
       DecimalFormat miformat = new DecimalFormat("############.##");
       Object[] fnewRow = new Object[10];
       int sihayhojacosto=0;
       String texto="select * from x1distribucion_terminados_hojacosto_catalogo(1,'"+busqueda.toUpperCase().trim()+"','') as (idterminado character varying(16),costostimadocon smallint,idinsumo character varying(16),cantidadcompo numeric,costoultimo numeric,costoprom numeric,observacion character varying(255),importe numeric,insumodescripcion character varying(80),unidadsal character varying(3),tipoinsudes character varying(40),idserial integer)";
       System.out.println(texto);
       try
        {
           rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                    sihayhojacosto=1;
                    fnewRow[0]=rs.getString("tipoinsudes");
                    fnewRow[1]=rs.getString("idinsumo");
                    fnewRow[2]=rs.getString("insumodescripcion");
                    fnewRow[3]=rs.getString("unidadsal");
                    fnewRow[4]=miformat.format(rs.getFloat("cantidadcompo"));
                    fnewRow[5]=miformat.format(rs.getFloat("costoultimo"));
                    fnewRow[6]=miformat.format(rs.getFloat("importe"));
                    fnewRow[7]=".";
                    fnewRow[8]=miformat.format(rs.getFloat("cantidadcompo"));
                    fnewRow[9]=miformat.format(rs.getFloat("importe"));
                    jtable_modelo_hojacosto.addRow(fnewRow);
                }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }
       if(sihayhojacosto==1)
            {
                this.jtf_idinsumo.setVisible(false);
                this.jbtn_idinsumobusca.setVisible(false);
                this.jbtn_guardarhoja.setVisible(false);
            }
       this.calcularimportes();
 }
 private void actualizar_articulo(int opcion){
    int confirma=0;
    String arreglo_status[]=this.jcbx_statusarticulo.getSelectedItem().toString().split(":");
    String arreglo_tempo[]=this.jcbx_temporada.getSelectedItem().toString().split(":");

    String arreglo_tipoele[]=this.jcbx_tipoelemento.getSelectedItem().toString().split(":");
    String arreglo_familia[]=this.jcbx_familia.getSelectedItem().toString().split(":");
    String arreglo_linea[]=this.jcbx_linea.getSelectedItem().toString().split(":");
    String arreglo_idpersonal[]=this.jcbx_idpersonal.getSelectedItem().toString().split(":");
    String textob=""+opcion+";"+this.jtf_codigobarra.getText().trim().toUpperCase()+";"+arreglo_status[0]+";"+this.jtf_descripcion.getText().trim().toUpperCase()+";"+this.jtf_descripcorta.getText().trim().toUpperCase()+";"+this.jtf_item.getText().trim().toUpperCase()+";"+this.jtf_unidadsalida.getText().trim().toUpperCase()+";"+this.jtf_unidadentrada.getText().trim().toUpperCase()+";"+this.jtf_factor.getText().trim().toUpperCase()+";"+this.jtf_unidadempake.getText().trim().toUpperCase()+";"+arreglo_tempo[0]+";"+arreglo_tipoele[0]+";"+arreglo_familia[0]+";"+arreglo_linea[0]+";"+this.jtf_controlalmacen.getText().trim().toUpperCase()+";"+this.jtf_stockminimo.getText().trim().toUpperCase()+";"+this.jtf_stockmaximo.getText().trim().toUpperCase()+";"+this.jtf_precio1.getText().trim().toUpperCase()+";"+this.jtf_precio2.getText().trim().toUpperCase()+";"+this.jtf_precio3.getText().trim().toUpperCase()+";"+this.jtf_precio4.getText().trim().toUpperCase()+";"+this.jtf_precio5.getText().trim().toUpperCase()+";"+this.jtf_ultimocosto.getText().trim()+";"+this.jtf_costopromedio.getText().trim().toUpperCase()+";"+this.jtf_tiemporsurtido.getText().trim()+";"+this.jtf_idproveedor.getText().trim().toUpperCase()+";"+arreglo_idpersonal[0]+";"+this.jtf_nombrecreador.getText().trim().toUpperCase()+";"+this.jtf_lugaralmacen.getText().trim().toUpperCase()+";"+this.jta_observacion.getText().trim().toUpperCase()+";"+this.jtf_clavearticulo.getText().trim().toUpperCase().replace("-", "").replace(".", "")+";"+this.jtf_clavebase.getText().trim().toUpperCase().replace("-", "")+"";
    String texto="select * from x1distribucion_terminados_articulos_actualizav2(1,'"+this.jtf_codigobarra.getText().trim().toUpperCase()+"','"+arreglo_status[0]+"','"+this.jtf_descripcion.getText().trim().toUpperCase()+"','"+this.jtf_descripcorta.getText().trim().toUpperCase()+"','"+this.jtf_item.getText().trim().toUpperCase()+"','"+this.jtf_unidadsalida.getText().trim().toUpperCase()+"','"+this.jtf_unidadentrada.getText().trim().toUpperCase()+"','"+this.jtf_factor.getText().trim().toUpperCase()+"','"+this.jtf_unidadempake.getText().trim().toUpperCase()+"','"+arreglo_tempo[0]+"','"+arreglo_tipoele[0]+"','"+arreglo_familia[0]+"','"+arreglo_linea[0]+"','"+this.jtf_controlalmacen.getText().trim().toUpperCase()+"','"+this.jtf_stockminimo.getText().trim().toUpperCase()+"','"+this.jtf_stockmaximo.getText().trim().toUpperCase()+"','"+this.jtf_precio1.getText().trim().toUpperCase()+"','"+this.jtf_precio2.getText().trim().toUpperCase()+"','"+this.jtf_precio3.getText().trim().toUpperCase()+"','"+this.jtf_precio4.getText().trim().toUpperCase()+"','"+this.jtf_precio5.getText().trim().toUpperCase()+"','"+this.jtf_ultimocosto.getText().trim()+"','"+this.jtf_costopromedio.getText().trim().toUpperCase()+"','"+this.jtf_tiemporsurtido.getText().trim()+"','"+this.jtf_idproveedor.getText().trim().toUpperCase()+"','"+arreglo_idpersonal[0]+"','"+this.jtf_nombrecreador.getText().trim().toUpperCase()+"','"+this.jtf_lugaralmacen.getText().trim().toUpperCase()+"','"+this.jta_observacion.getText().trim().toUpperCase()+"','"+this.jtf_clavearticulo.getText().trim()+"','"+this.jtf_clavebase.getText().trim().toUpperCase().replace("-", "")+"','0','0','0','"+variables_global.getLogin()+"','"+textob+"','0','0')";
    System.out.println(texto);
    try
         {
            rs = x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
            while (rs.next())
                {
                     confirma=rs.getInt(1);
                }
        }
        catch(Exception e)
        {
            System.out.println(e.getMessage());
        }
       if (confirma==1)
              {
                JOptionPane.showMessageDialog(null,"Gracias datos Actualizados Correctamente", "Sistema Integral Insumos",1);
              }
         else
              {
                JOptionPane.showMessageDialog(null,"Error Consulte con Su Administrador", "Sistema Integral Insumos",1);
              }
}

 private void calcularimportes()
    {
    int numerofilas=this.jtable_modelo_hojacosto.getRowCount(),error=0;
    DecimalFormat miformat = new DecimalFormat("############.##");
    DecimalFormat miformatd = new DecimalFormat("###,###,###,###.##");
    String punto="",comas="",imagen="";
    float cantidad=0,costo=0,importefila=0,importefilai=0,cantidadtermi=0,piezastotal=0,doctosubtotal=0,toimportimplo=0,doctodescuento=0,doctototal=0,piezasindi=0,piezamaqui=0,piezasmaquiindi=0;
     for(int i = 0 ;i < numerofilas; i++)
                {
                 try
                       {
                            cantidad = Float.valueOf(this.jtb_catalogo_artiexis.getValueAt(i, 4).toString()).floatValue();
                            piezastotal+=cantidad;
                            costo = Float.valueOf(this.jtb_catalogo_artiexis.getValueAt(i, 5).toString()).floatValue();
                            cantidadtermi=Float.valueOf(this.jtf_terminadasimplosion.getText().toString());
                            importefilai=((cantidad*costo)*cantidadtermi);
                            toimportimplo+=importefilai;
                            
                            importefila+=Float.valueOf(this.jtb_catalogo_artiexis.getValueAt(i, 6).toString()).floatValue();
                            doctosubtotal+=importefila;
                            jtable_modelo_hojacosto.setValueAt(miformat.format(cantidad*cantidadtermi), i,8);
                            jtable_modelo_hojacosto.setValueAt(miformat.format(importefilai), i,9);

                        }
                            catch (NumberFormatException nfe) {
                            cantidad=0;
                            costo=0;
                            error=1;
                        }


                }

    this.jtf_piezastotal.setText(miformatd.format(piezastotal));
    this.jtf_importecostohoja.setText(miformatd.format(doctosubtotal));
    this.jtf_importeimplosion.setText(miformatd.format(toimportimplo));
  
    }

 private String  fechaeuropea(String fecha) {

         //resibe cadena de fecha en formato americano yyyy-MM-dd
        java.util.Date fechaestaeuropa=null;
       SimpleDateFormat formateadorestaeuropa = new SimpleDateFormat("dd-MM-yyyy");
       String cadenafecha="";
        try
         {
          fechaestaeuropa = formateadoresta.parse(fecha);
         }
        catch (ParseException e)
          {
             //Error, la cadena de texto no se puede convertir en fecha.
          }
       cadenafecha= formateadorestaeuropa.format(fechaestaeuropa);
       return cadenafecha;

    }
 private String DiaSemana(String fe) {
         String dia = "";
       java.util.Date fecha=null;
         try
            {
             fecha = formateador.parse(fe);

           }
        catch (ParseException e)
            {
            //Error, la cadena de texto no se puede convertir en fecha.
            }
        Calendar cal= Calendar.getInstance();
        cal.setTime(fecha);
        //ojo para establecer o recetear cada parte de la fecha por separado
        //cal.set(Calendar.YEAR, fecha.getYear());
        //cal.set(Calendar.MONTH, fecha.getMonth());
        //cal.set(Calendar.DAY_OF_MONTH, fecha.getDay());
        int diaInt = cal.get(Calendar.DAY_OF_WEEK);
        switch (diaInt) {
            case 1:
                dia = "Domingo";
                break;
            case 2:
                dia = "Lunes";
                break;
            case 3:
                dia = "Martes";
                break;
            case 4:
                dia = "Miercoles";
                break;
            case 5:
                dia = "Jueves";
                break;
            case 6:
                dia = "Viernes";
                break;
            case 7:
                dia = "Sabado";
                break;

        }
        return dia;
    }
 private String  fechaamericana(String fecha) {

         //resibe cadena de fecha en formato americano dd-MM-yyyy
        java.util.Date fechaestaeuropa=null;
       SimpleDateFormat formateadorestaamericano = new SimpleDateFormat("yyyy-MM-dd");
       String cadenafecha="";
        try
         {
          fechaestaeuropa = formateador.parse(fecha);
         }
        catch (ParseException e)
          {
             //Error, la cadena de texto no se puede convertir en fecha.
          }
       cadenafecha= formateadorestaamericano.format(fechaestaeuropa);
       return cadenafecha;

    }
 private String  fechaamericana(Date fecha) {
       SimpleDateFormat formateadorestaeuropa = new SimpleDateFormat("yyyy-MM-dd");
       String cadenafecha="";

       cadenafecha= formateadorestaeuropa.format(fecha);
       return cadenafecha;

    }
    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jTabbedPane1 = new javax.swing.JTabbedPane();
        jPanel1 = new javax.swing.JPanel();
        jLabel1 = new javax.swing.JLabel();
        jtf_clavearticulo = new javax.swing.JTextField();
        jLabel3 = new javax.swing.JLabel();
        jtf_descripcion = new javax.swing.JTextField();
        jLabel2 = new javax.swing.JLabel();
        jtf_codigobarra = new javax.swing.JTextField();
        jcbx_statusarticulo = new javax.swing.JComboBox();
        jLabel5 = new javax.swing.JLabel();
        jLabel7 = new javax.swing.JLabel();
        jtf_item = new javax.swing.JTextField();
        jLabel27 = new javax.swing.JLabel();
        jtf_unidadsalida = new javax.swing.JTextField();
        jtf_unidadentrada = new javax.swing.JTextField();
        jLabel28 = new javax.swing.JLabel();
        jtf_factor = new javax.swing.JTextField();
        jLabel29 = new javax.swing.JLabel();
        jLabel6 = new javax.swing.JLabel();
        jcbx_tipoelemento = new javax.swing.JComboBox();
        jLabel8 = new javax.swing.JLabel();
        jcbx_familia = new javax.swing.JComboBox();
        jLabel9 = new javax.swing.JLabel();
        jcbx_linea = new javax.swing.JComboBox();
        jtf_controlalmacen = new javax.swing.JTextField();
        jLabel30 = new javax.swing.JLabel();
        jtf_stockminimo = new javax.swing.JTextField();
        jLabel31 = new javax.swing.JLabel();
        jtf_stockmaximo = new javax.swing.JTextField();
        jLabel32 = new javax.swing.JLabel();
        jLabel33 = new javax.swing.JLabel();
        jtf_precio1 = new javax.swing.JTextField();
        jLabel34 = new javax.swing.JLabel();
        jtf_precio2 = new javax.swing.JTextField();
        jLabel35 = new javax.swing.JLabel();
        jtf_ultimocosto = new javax.swing.JTextField();
        jLabel36 = new javax.swing.JLabel();
        jtf_costopromedio = new javax.swing.JTextField();
        jLabel37 = new javax.swing.JLabel();
        jLabel38 = new javax.swing.JLabel();
        jLabel10 = new javax.swing.JLabel();
        jtf_idproveedor = new javax.swing.JTextField();
        jtf_proveedordescribe = new javax.swing.JTextField();
        jLabel40 = new javax.swing.JLabel();
        jtf_lugaralmacen = new javax.swing.JTextField();
        jtf_existencia = new javax.swing.JTextField();
        jLabel11 = new javax.swing.JLabel();
        jScrollPane2 = new javax.swing.JScrollPane();
        jta_observacion = new javax.swing.JTextArea();
        jLabel13 = new javax.swing.JLabel();
        jbtn_guardacambios = new javax.swing.JButton();
        jbtn_salir = new javax.swing.JButton();
        jbtn_ayuda = new javax.swing.JButton();
        jLabel41 = new javax.swing.JLabel();
        jtf_unidadempake = new javax.swing.JTextField();
        jLabel4 = new javax.swing.JLabel();
        jtf_descripcorta = new javax.swing.JTextField();
        jLabel12 = new javax.swing.JLabel();
        jcbx_temporada = new javax.swing.JComboBox();
        jLabel42 = new javax.swing.JLabel();
        jtf_precio3 = new javax.swing.JTextField();
        jLabel43 = new javax.swing.JLabel();
        jtf_precio4 = new javax.swing.JTextField();
        jLabel44 = new javax.swing.JLabel();
        jtf_precio5 = new javax.swing.JTextField();
        jLabel45 = new javax.swing.JLabel();
        jtf_tiemporsurtido = new javax.swing.JTextField();
        jLabel46 = new javax.swing.JLabel();
        jtf_acumproducion = new javax.swing.JTextField();
        jLabel47 = new javax.swing.JLabel();
        jtf_acumimporte = new javax.swing.JTextField();
        jLabel48 = new javax.swing.JLabel();
        jtf_pendientesurtir = new javax.swing.JTextField();
        jLabel49 = new javax.swing.JLabel();
        jLabel50 = new javax.swing.JLabel();
        jPanel2 = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jep_articuloimagen = new javax.swing.JEditorPane();
        jtf_fechaprototipo = new javax.swing.JTextField();
        jtf_autoriza = new javax.swing.JTextField();
        jtf_inicioproduccion = new javax.swing.JTextField();
        jtf_fechaultcompra = new javax.swing.JTextField();
        jLabel14 = new javax.swing.JLabel();
        jtf_nombrecreador = new javax.swing.JTextField();
        jcbx_idpersonal = new javax.swing.JComboBox();
        jLabel15 = new javax.swing.JLabel();
        jbtn_buscar = new javax.swing.JButton();
        jLabel16 = new javax.swing.JLabel();
        jLabel22 = new javax.swing.JLabel();
        jtf_clavebase = new javax.swing.JTextField();
        jPanel3 = new javax.swing.JPanel();
        jPanel4 = new javax.swing.JPanel();
        jScrollPane3 = new javax.swing.JScrollPane();
        jtb_catalogo_artiexis = new javax.swing.JTable(){
            public boolean isCellEditable(int rowIndex, int mColIndex) {
                return false;
            }}
            ;
            jtf_idinsumo = new javax.swing.JTextField();
            jbtn_idinsumobusca = new javax.swing.JButton();
            jtf_idarticuloterminado = new javax.swing.JTextField();
            jLabel17 = new javax.swing.JLabel();
            jbtn_guardarhoja = new javax.swing.JButton();
            jLabel18 = new javax.swing.JLabel();
            jtf_terminadasimplosion = new javax.swing.JTextField();
            jLabel19 = new javax.swing.JLabel();
            jbtn_implosioncalcular = new javax.swing.JButton();
            jtf_piezastotal = new javax.swing.JTextField();
            jLabel20 = new javax.swing.JLabel();
            jLabel21 = new javax.swing.JLabel();
            jtf_importecostohoja = new javax.swing.JTextField();
            jLabel23 = new javax.swing.JLabel();
            jtf_importeimplosion = new javax.swing.JTextField();
            jPanel5 = new javax.swing.JPanel();
            jScrollPane4 = new javax.swing.JScrollPane();
            jtbl_kardex = new javax.swing.JTable(){
                public boolean isCellEditable(int rowIndex, int mColIndex) {
                    return false;
                }}
                ;
                jPanel6 = new javax.swing.JPanel();
                jPanel7 = new javax.swing.JPanel();
                jScrollPane7 = new javax.swing.JScrollPane();
                jtb_distribucionalta = new javax.swing.JTable()
                {
                    public boolean isCellEditable(int rowIndex, int mColIndex) {
                        if (mColIndex < 2)
                        return false;
                        else
                        return true;
                    }
                }
                ;
                jLabel24 = new javax.swing.JLabel();
                jScrollPane5 = new javax.swing.JScrollPane();
                jta_archivo = new javax.swing.JTextArea();
                jLabel25 = new javax.swing.JLabel();
                jbtn_importar = new javax.swing.JButton();
                jScrollPane6 = new javax.swing.JScrollPane();
                jtb_terminadosentrada = new javax.swing.JTable()
                //{
                    //  public boolean isCellEditable(int rowIndex, int mColIndex) {
                        //    if (mColIndex < 3)
                        //  return false;
                        //else
                        //return true;
                        //}
                    //}
                ;
                jLabel26 = new javax.swing.JLabel();
                jScrollPane8 = new javax.swing.JScrollPane();
                jtb_terminadosentrada1 = new javax.swing.JTable()
                //{
                    //  public boolean isCellEditable(int rowIndex, int mColIndex) {
                        //    if (mColIndex < 3)
                        //  return false;
                        //else
                        //return true;
                        //}
                    //}
                ;
                jbtn_importar1 = new javax.swing.JButton();
                jMenuBar1 = new javax.swing.JMenuBar();
                jMenu1 = new javax.swing.JMenu();
                jmni_salir = new javax.swing.JMenuItem();
                jMenu2 = new javax.swing.JMenu();
                jmni_escape = new javax.swing.JMenuItem();
                jmni_buscar = new javax.swing.JMenuItem();
                jmni_guardacambio = new javax.swing.JMenuItem();
                jmni_guardaf7 = new javax.swing.JMenuItem();

                setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
                setName("Form"); // NOI18N

                jTabbedPane1.setName("jTabbedPane1"); // NOI18N
                jTabbedPane1.addChangeListener(new javax.swing.event.ChangeListener() {
                    public void stateChanged(javax.swing.event.ChangeEvent evt) {
                        jTabbedPane1StateChanged(evt);
                    }
                });

                jPanel1.setName("jPanel1"); // NOI18N

                org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(sie_invdis.Sie_invdisApp.class).getContext().getResourceMap(com_distri_articulos_almacen_detalle.class);
                jLabel1.setText(resourceMap.getString("jLabel1.text")); // NOI18N
                jLabel1.setName("jLabel1"); // NOI18N

                jtf_clavearticulo.setEditable(false);
                jtf_clavearticulo.setName("jtf_clavearticulo"); // NOI18N

                jLabel3.setText(resourceMap.getString("jLabel3.text")); // NOI18N
                jLabel3.setName("jLabel3"); // NOI18N

                jtf_descripcion.setName("jtf_descripcion"); // NOI18N

                jLabel2.setText(resourceMap.getString("jLabel2.text")); // NOI18N
                jLabel2.setName("jLabel2"); // NOI18N

                jtf_codigobarra.setEditable(false);
                jtf_codigobarra.setName("jtf_codigobarra"); // NOI18N

                jcbx_statusarticulo.setName("jcbx_statusarticulo"); // NOI18N
                jcbx_statusarticulo.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jcbx_statusarticuloActionPerformed(evt);
                    }
                });

                jLabel5.setText(resourceMap.getString("jLabel5.text")); // NOI18N
                jLabel5.setName("jLabel5"); // NOI18N

                jLabel7.setText(resourceMap.getString("jLabel7.text")); // NOI18N
                jLabel7.setName("jLabel7"); // NOI18N

                jtf_item.setMinimumSize(new java.awt.Dimension(6, 18));
                jtf_item.setName("jtf_item"); // NOI18N
                jtf_item.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jtf_itemActionPerformed(evt);
                    }
                });

                jLabel27.setText(resourceMap.getString("jLabel27.text")); // NOI18N
                jLabel27.setName("jLabel27"); // NOI18N

                jtf_unidadsalida.setName("jtf_unidadsalida"); // NOI18N

                jtf_unidadentrada.setName("jtf_unidadentrada"); // NOI18N

                jLabel28.setText(resourceMap.getString("jLabel28.text")); // NOI18N
                jLabel28.setName("jLabel28"); // NOI18N

                jtf_factor.setName("jtf_factor"); // NOI18N

                jLabel29.setText(resourceMap.getString("jLabel29.text")); // NOI18N
                jLabel29.setName("jLabel29"); // NOI18N

                jLabel6.setText(resourceMap.getString("jLabel6.text")); // NOI18N
                jLabel6.setName("jLabel6"); // NOI18N

                jcbx_tipoelemento.setName("jcbx_tipoelemento"); // NOI18N
                jcbx_tipoelemento.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jcbx_tipoelementoActionPerformed(evt);
                    }
                });

                jLabel8.setText(resourceMap.getString("jLabel8.text")); // NOI18N
                jLabel8.setName("jLabel8"); // NOI18N

                jcbx_familia.setName("jcbx_familia"); // NOI18N
                jcbx_familia.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jcbx_familiaActionPerformed(evt);
                    }
                });

                jLabel9.setText(resourceMap.getString("jLabel9.text")); // NOI18N
                jLabel9.setName("jLabel9"); // NOI18N

                jcbx_linea.setName("jcbx_linea"); // NOI18N
                jcbx_linea.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jcbx_lineaActionPerformed(evt);
                    }
                });

                jtf_controlalmacen.setName("jtf_controlalmacen"); // NOI18N

                jLabel30.setText(resourceMap.getString("jLabel30.text")); // NOI18N
                jLabel30.setName("jLabel30"); // NOI18N

                jtf_stockminimo.setText(resourceMap.getString("jtf_stockminimo.text")); // NOI18N
                jtf_stockminimo.setName("jtf_stockminimo"); // NOI18N

                jLabel31.setText(resourceMap.getString("jLabel31.text")); // NOI18N
                jLabel31.setName("jLabel31"); // NOI18N

                jtf_stockmaximo.setText(resourceMap.getString("jtf_stockmaximo.text")); // NOI18N
                jtf_stockmaximo.setName("jtf_stockmaximo"); // NOI18N

                jLabel32.setText(resourceMap.getString("jLabel32.text")); // NOI18N
                jLabel32.setName("jLabel32"); // NOI18N

                jLabel33.setText(resourceMap.getString("jLabel33.text")); // NOI18N
                jLabel33.setName("jLabel33"); // NOI18N

                jtf_precio1.setName("jtf_precio1"); // NOI18N

                jLabel34.setText(resourceMap.getString("jLabel34.text")); // NOI18N
                jLabel34.setName("jLabel34"); // NOI18N

                jtf_precio2.setName("jtf_precio2"); // NOI18N

                jLabel35.setText(resourceMap.getString("jLabel35.text")); // NOI18N
                jLabel35.setName("jLabel35"); // NOI18N

                jtf_ultimocosto.setName("jtf_ultimocosto"); // NOI18N

                jLabel36.setText(resourceMap.getString("jLabel36.text")); // NOI18N
                jLabel36.setName("jLabel36"); // NOI18N

                jtf_costopromedio.setName("jtf_costopromedio"); // NOI18N

                jLabel37.setFont(resourceMap.getFont("jLabel37.font")); // NOI18N
                jLabel37.setText(resourceMap.getString("jLabel37.text")); // NOI18N
                jLabel37.setName("jLabel37"); // NOI18N

                jLabel38.setFont(resourceMap.getFont("jLabel38.font")); // NOI18N
                jLabel38.setText(resourceMap.getString("jLabel38.text")); // NOI18N
                jLabel38.setName("jLabel38"); // NOI18N

                jLabel10.setText(resourceMap.getString("jLabel10.text")); // NOI18N
                jLabel10.setName("jLabel10"); // NOI18N

                jtf_idproveedor.setName("jtf_idproveedor"); // NOI18N

                jtf_proveedordescribe.setEditable(false);
                jtf_proveedordescribe.setName("jtf_proveedordescribe"); // NOI18N

                jLabel40.setText(resourceMap.getString("jLabel40.text")); // NOI18N
                jLabel40.setName("jLabel40"); // NOI18N

                jtf_lugaralmacen.setName("jtf_lugaralmacen"); // NOI18N

                jtf_existencia.setEditable(false);
                jtf_existencia.setMinimumSize(new java.awt.Dimension(6, 18));
                jtf_existencia.setName("jtf_existencia"); // NOI18N
                jtf_existencia.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jtf_existenciaActionPerformed(evt);
                    }
                });

                jLabel11.setText(resourceMap.getString("jLabel11.text")); // NOI18N
                jLabel11.setName("jLabel11"); // NOI18N

                jScrollPane2.setName("jScrollPane2"); // NOI18N

                jta_observacion.setColumns(20);
                jta_observacion.setRows(5);
                jta_observacion.setName("jta_observacion"); // NOI18N
                jScrollPane2.setViewportView(jta_observacion);

                jLabel13.setText(resourceMap.getString("jLabel13.text")); // NOI18N
                jLabel13.setName("jLabel13"); // NOI18N

                jbtn_guardacambios.setIcon(resourceMap.getIcon("jbtn_guardacambios.icon")); // NOI18N
                jbtn_guardacambios.setText(resourceMap.getString("jbtn_guardacambios.text")); // NOI18N
                jbtn_guardacambios.setName("jbtn_guardacambios"); // NOI18N
                jbtn_guardacambios.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_guardacambiosActionPerformed(evt);
                    }
                });

                jbtn_salir.setIcon(resourceMap.getIcon("jbtn_salir.icon")); // NOI18N
                jbtn_salir.setText(resourceMap.getString("jbtn_salir.text")); // NOI18N
                jbtn_salir.setName("jbtn_salir"); // NOI18N
                jbtn_salir.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_salirActionPerformed(evt);
                    }
                });

                jbtn_ayuda.setIcon(resourceMap.getIcon("jbtn_ayuda.icon")); // NOI18N
                jbtn_ayuda.setText(resourceMap.getString("jbtn_ayuda.text")); // NOI18N
                jbtn_ayuda.setName("jbtn_ayuda"); // NOI18N
                jbtn_ayuda.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_ayudaActionPerformed(evt);
                    }
                });

                jLabel41.setText(resourceMap.getString("jLabel41.text")); // NOI18N
                jLabel41.setName("jLabel41"); // NOI18N

                jtf_unidadempake.setName("jtf_unidadempake"); // NOI18N

                jLabel4.setText(resourceMap.getString("jLabel4.text")); // NOI18N
                jLabel4.setName("jLabel4"); // NOI18N

                jtf_descripcorta.setText(resourceMap.getString("jtf_descripcorta.text")); // NOI18N
                jtf_descripcorta.setName("jtf_descripcorta"); // NOI18N

                jLabel12.setText(resourceMap.getString("jLabel12.text")); // NOI18N
                jLabel12.setName("jLabel12"); // NOI18N

                jcbx_temporada.setName("jcbx_temporada"); // NOI18N

                jLabel42.setText(resourceMap.getString("jLabel42.text")); // NOI18N
                jLabel42.setName("jLabel42"); // NOI18N

                jtf_precio3.setName("jtf_precio3"); // NOI18N

                jLabel43.setText(resourceMap.getString("jLabel43.text")); // NOI18N
                jLabel43.setName("jLabel43"); // NOI18N

                jtf_precio4.setName("jtf_precio4"); // NOI18N

                jLabel44.setText(resourceMap.getString("jLabel44.text")); // NOI18N
                jLabel44.setName("jLabel44"); // NOI18N

                jtf_precio5.setName("jtf_precio5"); // NOI18N

                jLabel45.setText(resourceMap.getString("jLabel45.text")); // NOI18N
                jLabel45.setName("jLabel45"); // NOI18N

                jtf_tiemporsurtido.setName("jtf_tiemporsurtido"); // NOI18N

                jLabel46.setText(resourceMap.getString("jLabel46.text")); // NOI18N
                jLabel46.setName("jLabel46"); // NOI18N

                jtf_acumproducion.setEditable(false);
                jtf_acumproducion.setName("jtf_acumproducion"); // NOI18N

                jLabel47.setText(resourceMap.getString("jLabel47.text")); // NOI18N
                jLabel47.setName("jLabel47"); // NOI18N

                jtf_acumimporte.setEditable(false);
                jtf_acumimporte.setName("jtf_acumimporte"); // NOI18N

                jLabel48.setText(resourceMap.getString("jLabel48.text")); // NOI18N
                jLabel48.setName("jLabel48"); // NOI18N

                jtf_pendientesurtir.setName("jtf_pendientesurtir"); // NOI18N

                jLabel49.setFont(resourceMap.getFont("jLabel49.font")); // NOI18N
                jLabel49.setText(resourceMap.getString("jLabel49.text")); // NOI18N
                jLabel49.setName("jLabel49"); // NOI18N

                jLabel50.setFont(resourceMap.getFont("jLabel50.font")); // NOI18N
                jLabel50.setText(resourceMap.getString("jLabel50.text")); // NOI18N
                jLabel50.setName("jLabel50"); // NOI18N

                jPanel2.setBorder(javax.swing.BorderFactory.createEtchedBorder());
                jPanel2.setName("jPanel2"); // NOI18N

                jScrollPane1.setName("jScrollPane1"); // NOI18N

                jep_articuloimagen.setContentType(resourceMap.getString("jep_articuloimagen.contentType")); // NOI18N
                jep_articuloimagen.setName("jep_articuloimagen"); // NOI18N
                jScrollPane1.setViewportView(jep_articuloimagen);

                javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
                jPanel2.setLayout(jPanel2Layout);
                jPanel2Layout.setHorizontalGroup(
                    jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 413, Short.MAX_VALUE)
                );
                jPanel2Layout.setVerticalGroup(
                    jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 340, Short.MAX_VALUE)
                );

                jtf_fechaprototipo.setEditable(false);
                jtf_fechaprototipo.setText(resourceMap.getString("jtf_fechaprototipo.text")); // NOI18N
                jtf_fechaprototipo.setName("jtf_fechaprototipo"); // NOI18N

                jtf_autoriza.setEditable(false);
                jtf_autoriza.setText(resourceMap.getString("jtf_autoriza.text")); // NOI18N
                jtf_autoriza.setName("jtf_autoriza"); // NOI18N

                jtf_inicioproduccion.setEditable(false);
                jtf_inicioproduccion.setText(resourceMap.getString("jtf_inicioproduccion.text")); // NOI18N
                jtf_inicioproduccion.setName("jtf_inicioproduccion"); // NOI18N

                jtf_fechaultcompra.setEditable(false);
                jtf_fechaultcompra.setText(resourceMap.getString("jtf_fechaultcompra.text")); // NOI18N
                jtf_fechaultcompra.setName("jtf_fechaultcompra"); // NOI18N

                jLabel14.setText(resourceMap.getString("jLabel14.text")); // NOI18N
                jLabel14.setName("jLabel14"); // NOI18N

                jtf_nombrecreador.setText(resourceMap.getString("jtf_nombrecreador.text")); // NOI18N
                jtf_nombrecreador.setName("jtf_nombrecreador"); // NOI18N

                jcbx_idpersonal.setName("jcbx_idpersonal"); // NOI18N

                jLabel15.setText(resourceMap.getString("jLabel15.text")); // NOI18N
                jLabel15.setName("jLabel15"); // NOI18N

                jbtn_buscar.setIcon(resourceMap.getIcon("jbtn_buscar.icon")); // NOI18N
                jbtn_buscar.setText(resourceMap.getString("jbtn_buscar.text")); // NOI18N
                jbtn_buscar.setName("jbtn_buscar"); // NOI18N
                jbtn_buscar.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_buscarActionPerformed(evt);
                    }
                });

                jLabel16.setText(resourceMap.getString("jLabel16.text")); // NOI18N
                jLabel16.setName("jLabel16"); // NOI18N

                jLabel22.setText(resourceMap.getString("jLabel22.text")); // NOI18N
                jLabel22.setName("jLabel22"); // NOI18N

                jtf_clavebase.setEditable(false);
                jtf_clavebase.setName("jtf_clavebase"); // NOI18N

                javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
                jPanel1.setLayout(jPanel1Layout);
                jPanel1Layout.setHorizontalGroup(
                    jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel1Layout.createSequentialGroup()
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel27)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_unidadsalida, javax.swing.GroupLayout.PREFERRED_SIZE, 60, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel28)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_unidadentrada, javax.swing.GroupLayout.PREFERRED_SIZE, 43, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel29)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_factor, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel41)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_unidadempake, javax.swing.GroupLayout.PREFERRED_SIZE, 112, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel12)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jcbx_temporada, javax.swing.GroupLayout.PREFERRED_SIZE, 145, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel6)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jcbx_tipoelemento, javax.swing.GroupLayout.PREFERRED_SIZE, 150, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                        .addComponent(jLabel8)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jcbx_familia, javax.swing.GroupLayout.PREFERRED_SIZE, 150, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel9)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jcbx_linea, javax.swing.GroupLayout.PREFERRED_SIZE, 150, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jbtn_guardacambios)
                                        .addGap(93, 93, 93)
                                        .addComponent(jbtn_salir)
                                        .addGap(128, 128, 128)
                                        .addComponent(jbtn_ayuda))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel1Layout.createSequentialGroup()
                                                .addComponent(jLabel1)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jtf_clavearticulo, javax.swing.GroupLayout.PREFERRED_SIZE, 147, javax.swing.GroupLayout.PREFERRED_SIZE)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                                .addComponent(jbtn_buscar)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jLabel2)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jtf_codigobarra))
                                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel1Layout.createSequentialGroup()
                                                .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 67, javax.swing.GroupLayout.PREFERRED_SIZE)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jtf_descripcion, javax.swing.GroupLayout.PREFERRED_SIZE, 354, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addGroup(jPanel1Layout.createSequentialGroup()
                                                .addComponent(jLabel4)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jtf_descripcorta, javax.swing.GroupLayout.PREFERRED_SIZE, 125, javax.swing.GroupLayout.PREFERRED_SIZE)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jLabel7)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                                .addComponent(jtf_item, javax.swing.GroupLayout.PREFERRED_SIZE, 137, javax.swing.GroupLayout.PREFERRED_SIZE))
                                            .addGroup(jPanel1Layout.createSequentialGroup()
                                                .addComponent(jLabel5)
                                                .addGap(18, 18, 18)
                                                .addComponent(jcbx_statusarticulo, javax.swing.GroupLayout.PREFERRED_SIZE, 150, javax.swing.GroupLayout.PREFERRED_SIZE)
                                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                                        .addGap(118, 118, 118)
                                                        .addComponent(jLabel16, javax.swing.GroupLayout.DEFAULT_SIZE, 215, Short.MAX_VALUE))
                                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                        .addComponent(jLabel22)
                                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                        .addComponent(jtf_clavebase, javax.swing.GroupLayout.PREFERRED_SIZE, 137, javax.swing.GroupLayout.PREFERRED_SIZE)))))))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED))
                            .addGroup(jPanel1Layout.createSequentialGroup()
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel32)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_controlalmacen, javax.swing.GroupLayout.PREFERRED_SIZE, 90, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel30)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_stockminimo, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                        .addComponent(jLabel31)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_stockmaximo, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel13)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 303, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(jLabel37)
                                            .addComponent(jLabel49))
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                            .addComponent(jtf_inicioproduccion)
                                            .addComponent(jtf_fechaprototipo, javax.swing.GroupLayout.DEFAULT_SIZE, 125, Short.MAX_VALUE))
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(jLabel38)
                                            .addComponent(jLabel50))
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                            .addComponent(jtf_fechaultcompra)
                                            .addComponent(jtf_autoriza, javax.swing.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE)))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel45)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_tiemporsurtido, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel46)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_acumproducion, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel47)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_acumimporte, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel40)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_lugaralmacen, javax.swing.GroupLayout.PREFERRED_SIZE, 167, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel11)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_existencia, javax.swing.GroupLayout.PREFERRED_SIZE, 61, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel1Layout.createSequentialGroup()
                                                .addComponent(jLabel14)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jtf_nombrecreador))
                                            .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel1Layout.createSequentialGroup()
                                                .addComponent(jLabel10)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jtf_idproveedor, javax.swing.GroupLayout.PREFERRED_SIZE, 47, javax.swing.GroupLayout.PREFERRED_SIZE)
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                                .addComponent(jtf_proveedordescribe, javax.swing.GroupLayout.PREFERRED_SIZE, 217, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                        .addGap(18, 18, 18)
                                        .addComponent(jLabel15)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                        .addComponent(jcbx_idpersonal, javax.swing.GroupLayout.PREFERRED_SIZE, 128, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel44)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_precio5, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel35)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_ultimocosto, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel36)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_costopromedio, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jLabel48)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_pendientesurtir))
                                    .addGroup(jPanel1Layout.createSequentialGroup()
                                        .addComponent(jLabel33)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_precio1, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addGap(18, 18, 18)
                                        .addComponent(jLabel34)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_precio2, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addGap(18, 18, 18)
                                        .addComponent(jLabel42)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_precio3, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addGap(18, 18, 18)
                                        .addComponent(jLabel43)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jtf_precio4, javax.swing.GroupLayout.PREFERRED_SIZE, 76, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                        .addGap(74, 74, 74))
                );
                jPanel1Layout.setVerticalGroup(
                    jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel1)
                            .addComponent(jtf_clavearticulo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jbtn_buscar)
                            .addComponent(jLabel16)
                            .addComponent(jLabel2)
                            .addComponent(jtf_codigobarra, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel5)
                            .addComponent(jcbx_statusarticulo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel22)
                            .addComponent(jtf_clavebase, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGap(18, 18, 18)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel3)
                            .addComponent(jtf_descripcion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel4)
                            .addComponent(jtf_descripcorta, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel7)
                            .addComponent(jtf_item, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGap(18, 18, 18)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel27)
                            .addComponent(jtf_unidadsalida, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel28)
                            .addComponent(jtf_unidadentrada, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel29)
                            .addComponent(jtf_factor, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel41)
                            .addComponent(jtf_unidadempake, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGap(18, 18, 18)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel12)
                            .addComponent(jcbx_temporada, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jcbx_tipoelemento, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel6)
                            .addComponent(jcbx_linea, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel9)
                            .addComponent(jcbx_familia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel8))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addGroup(jPanel1Layout.createSequentialGroup()
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jtf_controlalmacen, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel30)
                                    .addComponent(jtf_stockminimo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel31)
                                    .addComponent(jtf_stockmaximo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel32))
                                .addGap(18, 18, 18)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jtf_precio1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel34)
                                    .addComponent(jtf_precio2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel33)
                                    .addComponent(jtf_precio3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel43)
                                    .addComponent(jtf_precio4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel42))
                                .addGap(18, 18, 18)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel44)
                                    .addComponent(jtf_precio5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel35)
                                    .addComponent(jtf_ultimocosto, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel36)
                                    .addComponent(jtf_costopromedio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel48)
                                    .addComponent(jtf_pendientesurtir, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                .addGap(18, 18, 18)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel45)
                                    .addComponent(jtf_tiemporsurtido, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel46)
                                    .addComponent(jtf_acumproducion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel47)
                                    .addComponent(jtf_acumimporte, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                .addGap(18, 18, 18)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(jLabel37)
                                        .addComponent(jtf_fechaprototipo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(jLabel38)
                                        .addComponent(jtf_autoriza, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                .addGap(18, 18, 18)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(jLabel49)
                                        .addComponent(jtf_inicioproduccion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(jLabel50)
                                        .addComponent(jtf_fechaultcompra, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                                .addGap(18, 18, 18)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel10)
                                    .addComponent(jtf_idproveedor, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jtf_proveedordescribe, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jcbx_idpersonal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel15))
                                .addGap(18, 18, 18)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel14)
                                    .addComponent(jtf_nombrecreador, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel40)
                                    .addComponent(jtf_lugaralmacen, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel11)
                                    .addComponent(jtf_existencia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 38, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(jLabel13)))
                            .addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGap(12, 12, 12)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel1Layout.createSequentialGroup()
                                .addGap(4, 4, 4)
                                .addComponent(jbtn_guardacambios))
                            .addGroup(jPanel1Layout.createSequentialGroup()
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jbtn_salir)
                                    .addComponent(jbtn_ayuda))))
                        .addGap(40, 40, 40))
                );

                jTabbedPane1.addTab("Datos Generales", jPanel1);

                jPanel3.setName("jPanel3"); // NOI18N

                jPanel4.setBorder(javax.swing.BorderFactory.createTitledBorder(resourceMap.getString("jPanel4.border.title"))); // NOI18N
                jPanel4.setName("jPanel4"); // NOI18N

                jScrollPane3.setName("jScrollPane3"); // NOI18N

                jtb_catalogo_artiexis.setModel(this.jtable_modelo_hojacosto);
                jtb_catalogo_artiexis.setName("jtb_catalogo_artiexis"); // NOI18N
                jScrollPane3.setViewportView(jtb_catalogo_artiexis);

                jtf_idinsumo.setText(resourceMap.getString("jtf_idinsumo.text")); // NOI18N
                jtf_idinsumo.setName("jtf_idinsumo"); // NOI18N
                jtf_idinsumo.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jtf_idinsumoActionPerformed(evt);
                    }
                });

                jbtn_idinsumobusca.setText(resourceMap.getString("jbtn_idinsumobusca.text")); // NOI18N
                jbtn_idinsumobusca.setName("jbtn_idinsumobusca"); // NOI18N
                jbtn_idinsumobusca.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_idinsumobuscaActionPerformed(evt);
                    }
                });

                jtf_idarticuloterminado.setEditable(false);
                jtf_idarticuloterminado.setName("jtf_idarticuloterminado"); // NOI18N

                jLabel17.setText(resourceMap.getString("jLabel17.text")); // NOI18N
                jLabel17.setName("jLabel17"); // NOI18N

                jbtn_guardarhoja.setIcon(resourceMap.getIcon("jbtn_guardarhoja.icon")); // NOI18N
                jbtn_guardarhoja.setText(resourceMap.getString("jbtn_guardarhoja.text")); // NOI18N
                jbtn_guardarhoja.setName("jbtn_guardarhoja"); // NOI18N
                jbtn_guardarhoja.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_guardarhojaActionPerformed(evt);
                    }
                });

                jLabel18.setText(resourceMap.getString("jLabel18.text")); // NOI18N
                jLabel18.setName("jLabel18"); // NOI18N

                jtf_terminadasimplosion.setText(resourceMap.getString("jtf_terminadasimplosion.text")); // NOI18N
                jtf_terminadasimplosion.setName("jtf_terminadasimplosion"); // NOI18N
                jtf_terminadasimplosion.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jtf_terminadasimplosionActionPerformed(evt);
                    }
                });

                jLabel19.setText(resourceMap.getString("jLabel19.text")); // NOI18N
                jLabel19.setName("jLabel19"); // NOI18N

                jbtn_implosioncalcular.setText(resourceMap.getString("jbtn_implosioncalcular.text")); // NOI18N
                jbtn_implosioncalcular.setName("jbtn_implosioncalcular"); // NOI18N
                jbtn_implosioncalcular.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_implosioncalcularActionPerformed(evt);
                    }
                });

                jtf_piezastotal.setEditable(false);
                jtf_piezastotal.setText(resourceMap.getString("jtf_piezastotal.text")); // NOI18N
                jtf_piezastotal.setName("jtf_piezastotal"); // NOI18N

                jLabel20.setText(resourceMap.getString("jLabel20.text")); // NOI18N
                jLabel20.setName("jLabel20"); // NOI18N

                jLabel21.setText(resourceMap.getString("jLabel21.text")); // NOI18N
                jLabel21.setName("jLabel21"); // NOI18N

                jtf_importecostohoja.setEditable(false);
                jtf_importecostohoja.setName("jtf_importecostohoja"); // NOI18N

                jLabel23.setText(resourceMap.getString("jLabel23.text")); // NOI18N
                jLabel23.setName("jLabel23"); // NOI18N

                jtf_importeimplosion.setEditable(false);
                jtf_importeimplosion.setName("jtf_importeimplosion"); // NOI18N

                javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
                jPanel4.setLayout(jPanel4Layout);
                jPanel4Layout.setHorizontalGroup(
                    jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel4Layout.createSequentialGroup()
                                .addComponent(jLabel17)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_idarticuloterminado, javax.swing.GroupLayout.PREFERRED_SIZE, 147, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_idinsumo, javax.swing.GroupLayout.PREFERRED_SIZE, 123, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jbtn_idinsumobusca))
                            .addGroup(jPanel4Layout.createSequentialGroup()
                                .addComponent(jbtn_guardarhoja)
                                .addGap(66, 66, 66)
                                .addComponent(jLabel18, javax.swing.GroupLayout.PREFERRED_SIZE, 58, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addGroup(jPanel4Layout.createSequentialGroup()
                                .addGap(2, 2, 2)
                                .addComponent(jLabel19)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_terminadasimplosion, javax.swing.GroupLayout.PREFERRED_SIZE, 52, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jbtn_implosioncalcular)
                                .addGap(18, 18, 18)
                                .addComponent(jLabel20)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_piezastotal, javax.swing.GroupLayout.PREFERRED_SIZE, 93, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGap(18, 18, 18)
                                .addComponent(jLabel21)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                .addComponent(jtf_importecostohoja, javax.swing.GroupLayout.PREFERRED_SIZE, 93, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 121, Short.MAX_VALUE)
                                .addComponent(jLabel23)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(jtf_importeimplosion, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 961, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                );
                jPanel4Layout.setVerticalGroup(
                    jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel17)
                            .addComponent(jbtn_idinsumobusca)
                            .addComponent(jtf_idinsumo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jtf_idarticuloterminado, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 231, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel19)
                            .addComponent(jtf_terminadasimplosion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jbtn_implosioncalcular)
                            .addComponent(jLabel20)
                            .addComponent(jtf_piezastotal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel21)
                            .addComponent(jtf_importecostohoja, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel23)
                            .addComponent(jtf_importeimplosion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 12, Short.MAX_VALUE)
                        .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(jLabel18)
                            .addComponent(jbtn_guardarhoja)))
                );

                javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
                jPanel3.setLayout(jPanel3Layout);
                jPanel3Layout.setHorizontalGroup(
                    jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel3Layout.createSequentialGroup()
                        .addComponent(jPanel4, javax.swing.GroupLayout.PREFERRED_SIZE, 976, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                );
                jPanel3Layout.setVerticalGroup(
                    jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel3Layout.createSequentialGroup()
                        .addComponent(jPanel4, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap(201, Short.MAX_VALUE))
                );

                jTabbedPane1.addTab(resourceMap.getString("jPanel3.TabConstraints.tabTitle"), jPanel3); // NOI18N

                jPanel5.setName("jPanel5"); // NOI18N

                jScrollPane4.setName("jScrollPane4"); // NOI18N

                jtbl_kardex.setModel(this.jtable_modelo_kardex);
                jtbl_kardex.setName("jtbl_kardex"); // NOI18N
                jtbl_kardex.setRowHeight(22);
                jtbl_kardex.addMouseListener(new java.awt.event.MouseAdapter() {
                    public void mouseClicked(java.awt.event.MouseEvent evt) {
                        jtbl_kardexMouseClicked(evt);
                    }
                });
                jtbl_kardex.addKeyListener(new java.awt.event.KeyAdapter() {
                    public void keyPressed(java.awt.event.KeyEvent evt) {
                        jtbl_kardexKeyPressed(evt);
                    }
                });
                jScrollPane4.setViewportView(jtbl_kardex);

                javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);
                jPanel5.setLayout(jPanel5Layout);
                jPanel5Layout.setHorizontalGroup(
                    jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGap(0, 979, Short.MAX_VALUE)
                    .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel5Layout.createSequentialGroup()
                            .addComponent(jScrollPane4, javax.swing.GroupLayout.DEFAULT_SIZE, 969, Short.MAX_VALUE)
                            .addContainerGap()))
                );
                jPanel5Layout.setVerticalGroup(
                    jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGap(0, 557, Short.MAX_VALUE)
                    .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(jPanel5Layout.createSequentialGroup()
                            .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 544, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addContainerGap(13, Short.MAX_VALUE)))
                );

                jTabbedPane1.addTab(resourceMap.getString("jPanel5.TabConstraints.tabTitle"), jPanel5); // NOI18N

                jPanel6.setName("jPanel6"); // NOI18N

                jPanel7.setName("jPanel7"); // NOI18N

                jScrollPane7.setName("jScrollPane7"); // NOI18N

                jtb_distribucionalta.setModel(this.jtable_modelo_familia);
                jtb_distribucionalta.setName("jtb_distribucionalta"); // NOI18N
                jtb_distribucionalta.setRowHeight(22);
                jtb_distribucionalta.addPropertyChangeListener(new java.beans.PropertyChangeListener() {
                    public void propertyChange(java.beans.PropertyChangeEvent evt) {
                        jtb_distribucionaltaPropertyChange(evt);
                    }
                });
                jtb_distribucionalta.addKeyListener(new java.awt.event.KeyAdapter() {
                    public void keyPressed(java.awt.event.KeyEvent evt) {
                        jtb_distribucionaltaKeyPressed(evt);
                    }
                });
                jScrollPane7.setViewportView(jtb_distribucionalta);

                jLabel24.setText(resourceMap.getString("jLabel24.text")); // NOI18N
                jLabel24.setName("jLabel24"); // NOI18N

                jScrollPane5.setName("jScrollPane5"); // NOI18N

                jta_archivo.setColumns(20);
                jta_archivo.setRows(5);
                jta_archivo.setName("jta_archivo"); // NOI18N
                jScrollPane5.setViewportView(jta_archivo);

                jLabel25.setText(resourceMap.getString("jLabel25.text")); // NOI18N
                jLabel25.setName("jLabel25"); // NOI18N

                jbtn_importar.setText(resourceMap.getString("jbtn_importar.text")); // NOI18N
                jbtn_importar.setName("jbtn_importar"); // NOI18N
                jbtn_importar.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_importarActionPerformed(evt);
                    }
                });

                jScrollPane6.setName("jScrollPane6"); // NOI18N

                jtb_terminadosentrada.setModel(this.jtable_modelo_detallecompra);
                jtb_terminadosentrada.setName("jtb_terminadosentrada"); // NOI18N
                jtb_terminadosentrada.setRowHeight(23);
                jtb_terminadosentrada.addPropertyChangeListener(new java.beans.PropertyChangeListener() {
                    public void propertyChange(java.beans.PropertyChangeEvent evt) {
                        jtb_terminadosentradaPropertyChange(evt);
                    }
                });
                jtb_terminadosentrada.addKeyListener(new java.awt.event.KeyAdapter() {
                    public void keyPressed(java.awt.event.KeyEvent evt) {
                        jtb_terminadosentradaKeyPressed(evt);
                    }
                });
                jScrollPane6.setViewportView(jtb_terminadosentrada);

                jLabel26.setText(resourceMap.getString("jLabel26.text")); // NOI18N
                jLabel26.setName("jLabel26"); // NOI18N

                jScrollPane8.setName("jScrollPane8"); // NOI18N

                jtb_terminadosentrada1.setModel(this.jtable_modelo_detallecompray);
                jtb_terminadosentrada1.setName("jtb_terminadosentrada1"); // NOI18N
                jtb_terminadosentrada1.setRowHeight(23);
                jtb_terminadosentrada1.addPropertyChangeListener(new java.beans.PropertyChangeListener() {
                    public void propertyChange(java.beans.PropertyChangeEvent evt) {
                        jtb_terminadosentrada1PropertyChange(evt);
                    }
                });
                jtb_terminadosentrada1.addKeyListener(new java.awt.event.KeyAdapter() {
                    public void keyPressed(java.awt.event.KeyEvent evt) {
                        jtb_terminadosentrada1KeyPressed(evt);
                    }
                });
                jScrollPane8.setViewportView(jtb_terminadosentrada1);

                jbtn_importar1.setText(resourceMap.getString("jbtn_importar1.text")); // NOI18N
                jbtn_importar1.setName("jbtn_importar1"); // NOI18N
                jbtn_importar1.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jbtn_importar1ActionPerformed(evt);
                    }
                });

                javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);
                jPanel7.setLayout(jPanel7Layout);
                jPanel7Layout.setHorizontalGroup(
                    jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel7Layout.createSequentialGroup()
                                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(jPanel7Layout.createSequentialGroup()
                                        .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 677, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(jScrollPane7, javax.swing.GroupLayout.DEFAULT_SIZE, 276, Short.MAX_VALUE))
                                    .addGroup(jPanel7Layout.createSequentialGroup()
                                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(jLabel24, javax.swing.GroupLayout.PREFERRED_SIZE, 578, javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addGroup(jPanel7Layout.createSequentialGroup()
                                                .addComponent(jLabel25, javax.swing.GroupLayout.PREFERRED_SIZE, 488, javax.swing.GroupLayout.PREFERRED_SIZE)
                                                .addGap(54, 54, 54)
                                                .addComponent(jbtn_importar)))
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 342, Short.MAX_VALUE)))
                                .addGap(10, 10, 10))
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()
                                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(jPanel7Layout.createSequentialGroup()
                                        .addComponent(jLabel26, javax.swing.GroupLayout.PREFERRED_SIZE, 359, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addGap(174, 174, 174)
                                        .addComponent(jbtn_importar1))
                                    .addComponent(jScrollPane8, javax.swing.GroupLayout.DEFAULT_SIZE, 959, Short.MAX_VALUE))
                                .addContainerGap())))
                    .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(jPanel7Layout.createSequentialGroup()
                            .addContainerGap()
                            .addComponent(jScrollPane6, javax.swing.GroupLayout.DEFAULT_SIZE, 959, Short.MAX_VALUE)
                            .addContainerGap()))
                );
                jPanel7Layout.setVerticalGroup(
                    jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel7Layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel7Layout.createSequentialGroup()
                                .addComponent(jLabel24)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                .addComponent(jScrollPane5, javax.swing.GroupLayout.PREFERRED_SIZE, 118, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGap(10, 10, 10)
                                .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                    .addComponent(jLabel25)
                                    .addComponent(jbtn_importar)))
                            .addGroup(jPanel7Layout.createSequentialGroup()
                                .addGap(15, 15, 15)
                                .addComponent(jScrollPane7, javax.swing.GroupLayout.PREFERRED_SIZE, 136, javax.swing.GroupLayout.PREFERRED_SIZE)))
                        .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanel7Layout.createSequentialGroup()
                                .addGap(190, 190, 190)
                                .addComponent(jLabel26)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED))
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel7Layout.createSequentialGroup()
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 175, Short.MAX_VALUE)
                                .addComponent(jbtn_importar1)
                                .addGap(26, 26, 26)))
                        .addComponent(jScrollPane8, javax.swing.GroupLayout.PREFERRED_SIZE, 127, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addGroup(jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(jPanel7Layout.createSequentialGroup()
                            .addGap(189, 189, 189)
                            .addComponent(jScrollPane6, javax.swing.GroupLayout.PREFERRED_SIZE, 167, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addContainerGap(193, Short.MAX_VALUE)))
                );

                javax.swing.GroupLayout jPanel6Layout = new javax.swing.GroupLayout(jPanel6);
                jPanel6.setLayout(jPanel6Layout);
                jPanel6Layout.setHorizontalGroup(
                    jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanel7, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                );
                jPanel6Layout.setVerticalGroup(
                    jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanel7, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                );

                jTabbedPane1.addTab(resourceMap.getString("jPanel6.TabConstraints.tabTitle"), jPanel6); // NOI18N

                jMenuBar1.setName("jMenuBar1"); // NOI18N

                jMenu1.setText(resourceMap.getString("jMenu1.text")); // NOI18N
                jMenu1.setName("jMenu1"); // NOI18N

                jmni_salir.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.ALT_MASK));
                jmni_salir.setIcon(resourceMap.getIcon("jmni_salir.icon")); // NOI18N
                jmni_salir.setText(resourceMap.getString("jmni_salir.text")); // NOI18N
                jmni_salir.setName("jmni_salir"); // NOI18N
                jmni_salir.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jmni_salirActionPerformed(evt);
                    }
                });
                jMenu1.add(jmni_salir);

                jMenuBar1.add(jMenu1);

                jMenu2.setText(resourceMap.getString("jMenu2.text")); // NOI18N
                jMenu2.setName("jMenu2"); // NOI18N

                jmni_escape.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_ESCAPE, 0));
                jmni_escape.setText(resourceMap.getString("jmni_escape.text")); // NOI18N
                jmni_escape.setName("jmni_escape"); // NOI18N
                jmni_escape.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jmni_escapeActionPerformed(evt);
                    }
                });
                jMenu2.add(jmni_escape);

                jmni_buscar.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_B, java.awt.event.InputEvent.CTRL_MASK));
                jmni_buscar.setText(resourceMap.getString("jmni_buscar.text")); // NOI18N
                jmni_buscar.setName("jmni_buscar"); // NOI18N
                jmni_buscar.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jmni_buscarActionPerformed(evt);
                    }
                });
                jMenu2.add(jmni_buscar);

                jmni_guardacambio.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_G, java.awt.event.InputEvent.ALT_MASK));
                jmni_guardacambio.setText(resourceMap.getString("jmni_guardacambio.text")); // NOI18N
                jmni_guardacambio.setName("jmni_guardacambio"); // NOI18N
                jmni_guardacambio.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jmni_guardacambioActionPerformed(evt);
                    }
                });
                jMenu2.add(jmni_guardacambio);

                jmni_guardaf7.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_F7, 0));
                jmni_guardaf7.setText(resourceMap.getString("jmni_guardaf7.text")); // NOI18N
                jmni_guardaf7.setName("jmni_guardaf7"); // NOI18N
                jmni_guardaf7.addActionListener(new java.awt.event.ActionListener() {
                    public void actionPerformed(java.awt.event.ActionEvent evt) {
                        jmni_guardaf7ActionPerformed(evt);
                    }
                });
                jMenu2.add(jmni_guardaf7);

                jMenuBar1.add(jMenu2);

                setJMenuBar(jMenuBar1);

                javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
                getContentPane().setLayout(layout);
                layout.setHorizontalGroup(
                    layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jTabbedPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 984, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                );
                layout.setVerticalGroup(
                    layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jTabbedPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 585, javax.swing.GroupLayout.PREFERRED_SIZE)
                );

                pack();
            }// </editor-fold>//GEN-END:initComponents

    private void jmni_salirActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_salirActionPerformed
        // TODO add your handling code here:
    if(JOptionPane.showConfirmDialog(null, "Desea Salir?")==0)
            {
                this.dispose();
                }
    }//GEN-LAST:event_jmni_salirActionPerformed

    private void jcbx_statusarticuloActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_statusarticuloActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jcbx_statusarticuloActionPerformed

    private void jtf_itemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_itemActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jtf_itemActionPerformed

    private void jcbx_tipoelementoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_tipoelementoActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jcbx_tipoelementoActionPerformed

    private void jcbx_familiaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_familiaActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jcbx_familiaActionPerformed

    private void jcbx_lineaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbx_lineaActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jcbx_lineaActionPerformed

    private void jtf_existenciaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_existenciaActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jtf_existenciaActionPerformed

    private void jbtn_guardacambiosActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_guardacambiosActionPerformed
        // TODO add your handling code here:
        if(JOptionPane.showConfirmDialog(null, "Estan Correctos sus Datos?")==0) {
           this.jtf_clavebase.setText(this.jtf_clavearticulo.getText().toUpperCase().replace("-", "").replace(",", "."));
           this.actualizar_articulo(opcionupdate);
        }
}//GEN-LAST:event_jbtn_guardacambiosActionPerformed

    private void jbtn_salirActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_salirActionPerformed
        // TODO add your handling code here:
        this.jmni_salirActionPerformed(evt);
}//GEN-LAST:event_jbtn_salirActionPerformed

    private void jbtn_ayudaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_ayudaActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jbtn_ayudaActionPerformed

    private void jmni_escapeActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_escapeActionPerformed
        // TODO add your handling code here:
        this.jmni_salirActionPerformed(evt);
    }//GEN-LAST:event_jmni_escapeActionPerformed

    private void jmni_buscarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_buscarActionPerformed
        // TODO add your handling code here:
        this.jbtn_buscarActionPerformed(evt);
    }//GEN-LAST:event_jmni_buscarActionPerformed

    private void jbtn_buscarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_buscarActionPerformed
        // TODO add your handling code here:
          String textbusca="";
         textbusca=JOptionPane.showInputDialog("Ingresa Clave:",this.jtf_clavearticulo.getText());
         if (textbusca.length() > 0)
            {
              this.carga_datos_catalogoarticulos_almacen(1, 1, textbusca.toUpperCase().trim());
              this.jtf_descripcion.requestFocus();
              yacarguehoja=0;
              yacarguekardex=0;
            }
    }//GEN-LAST:event_jbtn_buscarActionPerformed

    private void jmni_guardacambioActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_guardacambioActionPerformed
        // TODO add your handling code here:
        this.jbtn_guardacambiosActionPerformed(evt);
    }//GEN-LAST:event_jmni_guardacambioActionPerformed

    private void jmni_guardaf7ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jmni_guardaf7ActionPerformed
        // TODO add your handling code here:
        this.jbtn_guardacambiosActionPerformed(evt);
    }//GEN-LAST:event_jmni_guardaf7ActionPerformed

    private void jbtn_idinsumobuscaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_idinsumobuscaActionPerformed
        // TODO add your handling code here:
        if(JOptionPane.showConfirmDialog(null, "Estan Correctos sus Datos?")==0)
                        {
                            this.carga_datos_hojacosto(this.jtf_idinsumo.getText());
                        }
                        else
                        {
                            this.jtf_idinsumo.requestFocus();
                        }
    }//GEN-LAST:event_jbtn_idinsumobuscaActionPerformed

    private void jbtn_guardarhojaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_guardarhojaActionPerformed
        // TODO add your handling code here:
        if(JOptionPane.showConfirmDialog(null, "Estan Correctos sus Datos?")==0)
            {
             int numerofilas=this.jtable_modelo_hojacosto.getRowCount();
             String comas="";
             for(int i = 0 ;i < numerofilas; i++)
                {
                      comas=jtable_modelo_hojacosto.getValueAt(i, 7).toString().replace(",", "").replace(".", "");
                      jtable_modelo_hojacosto.setValueAt(comas+".", i,7);
                }
                java.util.Vector arreglodearticulos=this.jtable_modelo_hojacosto.getDataVector();
                String articulos_papostgresql=arreglodearticulos.toString();
                articulos_papostgresql=articulos_papostgresql.replace('[','{');
                articulos_papostgresql=articulos_papostgresql.replace(']','}');
                articulos_papostgresql=articulos_papostgresql.replace("null",".");
                String texto="select * from x1distribucion_terminados_hojacosto_insumos(1,'"+this.jtf_idarticuloterminado.getText().trim()+"','1','"+articulos_papostgresql+"')";
                System.out.println(texto);
                try {
                    rs=x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
                    while (rs.next())
                        {
                            if (rs.getInt(1) > 0)
                                {
                                    JOptionPane.showMessageDialog(null,"Hoja de Costo, Gracias", "Sistema Integral(Hoja Costo) : Confirmacion",1);
                                }
                            else
                                {
                                    JOptionPane.showMessageDialog(null," Error Verifique sus Datos", "Sistema Integral(Hoja Costo) : Error",1);
                                }
                         }
                 }catch(Exception e)
                     {
                         System.out.println(e.getMessage());
                         JOptionPane.showMessageDialog(null," Hoja de Costo Incorrecta ", "Sistema Integral(Hoja de Costo) : Error",1);
                     }
            }
}//GEN-LAST:event_jbtn_guardarhojaActionPerformed

    private void jtf_idinsumoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_idinsumoActionPerformed
        // TODO add your handling code here:
        this.jbtn_idinsumobuscaActionPerformed(evt);
    }//GEN-LAST:event_jtf_idinsumoActionPerformed

    private void jTabbedPane1StateChanged(javax.swing.event.ChangeEvent evt) {//GEN-FIRST:event_jTabbedPane1StateChanged
        // TODO add your handling code here:
        indexactual=this.jTabbedPane1.getSelectedIndex();
           if((indexactual==1)&&(yacarguehoja==0))
            {
                yacarguehoja=1;
                this.carga_datos_hojacostover(this.jtf_idarticuloterminado.getText());
            }
        if((indexactual==2)&&(yacarguekardex==0))
            {
                yacarguekardex=1;
                this.carga_datos_kardex(2, this.jtf_clavearticulo.getText(), "0");
            }
    }//GEN-LAST:event_jTabbedPane1StateChanged

    private void jbtn_implosioncalcularActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_implosioncalcularActionPerformed
        // TODO add your handling code here:
        this.calcularimportes();
    }//GEN-LAST:event_jbtn_implosioncalcularActionPerformed

    private void jtf_terminadasimplosionActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtf_terminadasimplosionActionPerformed
        // TODO add your handling code here:
        this.jbtn_implosioncalcularActionPerformed(evt);
    }//GEN-LAST:event_jtf_terminadasimplosionActionPerformed

    private void jtbl_kardexMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jtbl_kardexMouseClicked
        // TODO add your handling code here:
}//GEN-LAST:event_jtbl_kardexMouseClicked

    private void jtbl_kardexKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jtbl_kardexKeyPressed
        // TODO add your handling code here:
}//GEN-LAST:event_jtbl_kardexKeyPressed

    private void jbtn_importarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_importarActionPerformed
        // TODO add your handling code here:
         Object[] fnewRowdet = new Object[13];
         int ii=0,findf=0,findp=0;
         String idfamex[]=null,idfam="",idpro="",idproa="",prodes="";
        if(JOptionPane.showConfirmDialog(null, "Desea Importar Estos Articulos?")==0) {
            errorf=0;
            errorp=0;
            while(jtable_modelo_detallecompra.getRowCount()>0)jtable_modelo_detallecompra.removeRow(0);
            while(jtable_modelo_detallecompray.getRowCount()>0)jtable_modelo_detallecompray.removeRow(0);
            String arreglo_importa[]=this.jta_archivo.getText().split("\n");
            String arreglo_codigo[]=null;
            System.out.println("Estos tiene archivo:"+arreglo_importa.length);
            for (int i=0;i<arreglo_importa.length;i++) {
                arreglo_codigo=arreglo_importa[i].split(",");
                banderafin=0;
                this.carga_datos_catalogoarticulosalta(12,1,arreglo_codigo[2].trim().toUpperCase());
                if(banderafin==0)
                    {
                        findf=0;
                        fnewRowdet[0]=arreglo_codigo[2].trim().toUpperCase(); //codigo
                        fnewRowdet[1]=arreglo_codigo[4].trim().toUpperCase();//descripcion
                        fnewRowdet[2]=arreglo_codigo[5].trim().toUpperCase();//descripcion
                        if(arreglo_codigo[5].trim().toString().length()>19)
                            fnewRowdet[3]=arreglo_codigo[5].trim().toUpperCase().substring(0, 19);//desc. corta
                        else
                            fnewRowdet[3]=arreglo_codigo[5].trim().toUpperCase();//desc. corta

                        fnewRowdet[4]=arreglo_codigo[3].trim().toUpperCase();//item original proveedor
                        fnewRowdet[5]=arreglo_codigo[3].trim().toUpperCase();//Item Derivado michelle
                        fnewRowdet[6]="PZ";
                        fnewRowdet[7]=arreglo_codigo[7].trim().toUpperCase();
                        fnewRowdet[8]=arreglo_codigo[8].trim().toUpperCase();
                        idfam=arreglo_codigo[2].trim().toUpperCase().substring(2, 3);
                        findf=0;
                        for( ii=0;ii<this.jtable_modelo_familia.getRowCount();ii++)
                                {
                                    idfamex=jtable_modelo_familia.getValueAt(ii, 2).toString().split(",");
                                     System.out.println("Agregando:"+idfamex[0]+" familia clave"+idfam);
                                    if (idfam.equals("A"))
                                    {
                                        if(Float.valueOf(arreglo_codigo[8].trim().toUpperCase())<50)
                                            {
                                                fnewRowdet[9]="B";
                                                fnewRowdet[10]="F.ECO";
                                            }
                                        else
                                            {
                                                fnewRowdet[9]="A";
                                                fnewRowdet[10]="F.FINA";
                                            }
                                           findf=1;
                                    }
                                    else
                                        {
                                        if (idfamex[0].equals(idfam))
                                            {
                                                //System.out.println("Tienda "+mesactual[0]+"Existencia="+rs.getString("exi"));
                                                fnewRowdet[9]=jtable_modelo_familia.getValueAt(ii, 0).toString();
                                                fnewRowdet[10]=jtable_modelo_familia.getValueAt(ii, 1).toString();
                                                findf=1;
                                            }
                                        if(idfamex.length==2)
                                            {
                                            if (idfamex[1].equals(idfam))
                                                {
                                                    //System.out.println("Tienda "+mesactual[0]+"Existencia="+rs.getString("exi"));
                                                    fnewRowdet[9]=jtable_modelo_familia.getValueAt(ii, 0).toString();
                                                    fnewRowdet[10]=jtable_modelo_familia.getValueAt(ii, 1).toString();
                                                    findf=1;
                                                }
                                            }
                                        }
                                }
                        if(findf==0)
                            {
                                JOptionPane.showMessageDialog(null,"<html><h2>Familia: "+idfam+" no encontrado por favor de de alta y reinicie este proceso</h2></html>", "Sistema Integral(Alta) : Confirmacion",1);
                            }
                        if((findf==0)&&(errorf==0))
                        {
                            errorf=1;
                        }
                        fnewRowdet[11]=arreglo_codigo[2].trim().toUpperCase().substring(0, 2);
                        idpro=arreglo_codigo[2].trim().toUpperCase().substring(0, 2);
                        findp=0;
                        if(!idproa.equals(idpro))
                            {
                             System.out.println("Pro:"+idproa+" proactual"+idpro);
                                try
                                {
                                    rs = x.sieuno_executediversosv2("select * from x1distribucion_terminados_proveedores(7,'"+idpro+"') as (idpro character varying(12),descripcion character varying(60));",variables_global.getconexiongral());
                                    while (rs.next())
                                        {
                                        fnewRowdet[12]=rs.getString("descripcion");
                                        prodes=rs.getString("descripcion");
                                        findp=1;
                                        }
                                }
                                catch(Exception e)
                                    {
                                        System.out.println(e.getMessage());
                                    }
                                    if(findp==0)
                                    {
                                        JOptionPane.showMessageDialog(null,"<html><h2>Proveedor: "+idpro+" no encontrado por favor de de alta y reinicie este proceso</h2></html>", "Sistema Integral(Alta) : Confirmacion",1);
                                    }
                                }
                        else
                            {
                                fnewRowdet[12]=prodes;
                                findp=1;
                            }
                        idproa=idpro;
                        if((findp==0)&&(errorp==0))
                        {
                            errorp=1;
                        }
                        System.out.println("error de proveedor");
                        if((errorp==0)&&(errorf==0))
                        {
                            jtable_modelo_detallecompra.addRow(fnewRowdet);
                        }
                        
                    }
            }
            this.jta_archivo.setText("");
        }
}//GEN-LAST:event_jbtn_importarActionPerformed

    private void jtb_distribucionaltaPropertyChange(java.beans.PropertyChangeEvent evt) {//GEN-FIRST:event_jtb_distribucionaltaPropertyChange
        // TODO add your handling code here:
    
}//GEN-LAST:event_jtb_distribucionaltaPropertyChange

    private void jtb_distribucionaltaKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jtb_distribucionaltaKeyPressed
        // TODO add your handling code here:
}//GEN-LAST:event_jtb_distribucionaltaKeyPressed

    private void jtb_terminadosentradaPropertyChange(java.beans.PropertyChangeEvent evt) {//GEN-FIRST:event_jtb_terminadosentradaPropertyChange
        // TODO add your handling code here:
        this.calcularimportes();
      
}//GEN-LAST:event_jtb_terminadosentradaPropertyChange

    private void jtb_terminadosentradaKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jtb_terminadosentradaKeyPressed
        // TODO add your handling code here:
        System.out.println(evt.getKeyCode());
        System.out.println("Hola");
        if (evt.getKeyCode() == 10) {
            try {
                // this.calcularimportes();
            } catch (Exception ex) {
                System.out.println("ERROR no ha elegido en el cuadro de texto");
            }
        }
}//GEN-LAST:event_jtb_terminadosentradaKeyPressed

    private void jtb_terminadosentrada1PropertyChange(java.beans.PropertyChangeEvent evt) {//GEN-FIRST:event_jtb_terminadosentrada1PropertyChange
        // TODO add your handling code here:
    }//GEN-LAST:event_jtb_terminadosentrada1PropertyChange

    private void jtb_terminadosentrada1KeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jtb_terminadosentrada1KeyPressed
        // TODO add your handling code here:
    }//GEN-LAST:event_jtb_terminadosentrada1KeyPressed

    private void jbtn_importar1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtn_importar1ActionPerformed
        // TODO add your handling code here:
         if((errorf==0)&&(errorp==0))
            {
            if(JOptionPane.showConfirmDialog(null, "<html><h2>Articulos:"+this.jtable_modelo_detallecompra.getRowCount()+"<br>seran Guardados. Estan correcto sus Datos?</h2></html>")==0)
                    {
                    java.util.Vector arreglodearticulos=this.jtable_modelo_detallecompra.getDataVector();
                    String articulos_papostgresql=arreglodearticulos.toString();
                    articulos_papostgresql=articulos_papostgresql.replace('[','{');
                    articulos_papostgresql=articulos_papostgresql.replace(']','}');
                    articulos_papostgresql=articulos_papostgresql.replace("null",".");
                    String texto="select * from x1distribucion_terminados_articulos_alta(1,1,'"+variables_global.getLogin()+"','"+articulos_papostgresql+"')";
                    System.out.println(texto);
                    try
                        {
                        rs=x.sieuno_executediversosv2(texto,variables_global.getconexiongral());
                        while (rs.next())
                            {
                            if (rs.getInt(1) > 0)
                                    {
                                        JOptionPane.showMessageDialog(null," Alta Correcta,Gracias!", "Sistema Integral(Alta Articulos)",1);
                                        while(jtable_modelo_detallecompra.getRowCount()>0)jtable_modelo_detallecompra.removeRow(0);
                                        while(jtable_modelo_detallecompray.getRowCount()>0)jtable_modelo_detallecompray.removeRow(0);

                                    }
                                else
                                    {
                                        JOptionPane.showMessageDialog(null," Error Verifique sus Cantidades", "Sistema Integral(Alta Compra) : Error",1);
                                    }
                            }
                        }
                    catch(Exception e) {
                        System.out.println(e.getMessage());
                        JOptionPane.showMessageDialog(null," Alta incorrecta ", "Sistema Integral(Alta Compra) : Error",1);
                    }
            }
         }
         else
            {
                JOptionPane.showMessageDialog(null," Error Verifique que sus articulos tengan familia y proveedor correctamente", "Sistema Integral(Alta Compra) : Error",1);
            }
    }//GEN-LAST:event_jbtn_importar1ActionPerformed

    /**
    * @param args the command line arguments
    */
    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new com_distri_articulos_almacen_detalle().setVisible(true);
            }
        });
    }

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel12;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel19;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel20;
    private javax.swing.JLabel jLabel21;
    private javax.swing.JLabel jLabel22;
    private javax.swing.JLabel jLabel23;
    private javax.swing.JLabel jLabel24;
    private javax.swing.JLabel jLabel25;
    private javax.swing.JLabel jLabel26;
    private javax.swing.JLabel jLabel27;
    private javax.swing.JLabel jLabel28;
    private javax.swing.JLabel jLabel29;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel30;
    private javax.swing.JLabel jLabel31;
    private javax.swing.JLabel jLabel32;
    private javax.swing.JLabel jLabel33;
    private javax.swing.JLabel jLabel34;
    private javax.swing.JLabel jLabel35;
    private javax.swing.JLabel jLabel36;
    private javax.swing.JLabel jLabel37;
    private javax.swing.JLabel jLabel38;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel40;
    private javax.swing.JLabel jLabel41;
    private javax.swing.JLabel jLabel42;
    private javax.swing.JLabel jLabel43;
    private javax.swing.JLabel jLabel44;
    private javax.swing.JLabel jLabel45;
    private javax.swing.JLabel jLabel46;
    private javax.swing.JLabel jLabel47;
    private javax.swing.JLabel jLabel48;
    private javax.swing.JLabel jLabel49;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel50;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JMenu jMenu1;
    private javax.swing.JMenu jMenu2;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JPanel jPanel3;
    private javax.swing.JPanel jPanel4;
    private javax.swing.JPanel jPanel5;
    private javax.swing.JPanel jPanel6;
    private javax.swing.JPanel jPanel7;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JScrollPane jScrollPane5;
    private javax.swing.JScrollPane jScrollPane6;
    private javax.swing.JScrollPane jScrollPane7;
    private javax.swing.JScrollPane jScrollPane8;
    private javax.swing.JTabbedPane jTabbedPane1;
    private javax.swing.JButton jbtn_ayuda;
    private javax.swing.JButton jbtn_buscar;
    private javax.swing.JButton jbtn_guardacambios;
    private javax.swing.JButton jbtn_guardarhoja;
    private javax.swing.JButton jbtn_idinsumobusca;
    private javax.swing.JButton jbtn_implosioncalcular;
    private javax.swing.JButton jbtn_importar;
    private javax.swing.JButton jbtn_importar1;
    private javax.swing.JButton jbtn_salir;
    private javax.swing.JComboBox jcbx_familia;
    private javax.swing.JComboBox jcbx_idpersonal;
    private javax.swing.JComboBox jcbx_linea;
    private javax.swing.JComboBox jcbx_statusarticulo;
    private javax.swing.JComboBox jcbx_temporada;
    private javax.swing.JComboBox jcbx_tipoelemento;
    private javax.swing.JEditorPane jep_articuloimagen;
    private javax.swing.JMenuItem jmni_buscar;
    private javax.swing.JMenuItem jmni_escape;
    private javax.swing.JMenuItem jmni_guardacambio;
    private javax.swing.JMenuItem jmni_guardaf7;
    private javax.swing.JMenuItem jmni_salir;
    private javax.swing.JTextArea jta_archivo;
    private javax.swing.JTextArea jta_observacion;
    private javax.swing.JTable jtb_catalogo_artiexis;
    private javax.swing.JTable jtb_distribucionalta;
    private javax.swing.JTable jtb_terminadosentrada;
    private javax.swing.JTable jtb_terminadosentrada1;
    private javax.swing.JTable jtbl_kardex;
    private javax.swing.JTextField jtf_acumimporte;
    private javax.swing.JTextField jtf_acumproducion;
    private javax.swing.JTextField jtf_autoriza;
    private javax.swing.JTextField jtf_clavearticulo;
    private javax.swing.JTextField jtf_clavebase;
    private javax.swing.JTextField jtf_codigobarra;
    private javax.swing.JTextField jtf_controlalmacen;
    private javax.swing.JTextField jtf_costopromedio;
    private javax.swing.JTextField jtf_descripcion;
    private javax.swing.JTextField jtf_descripcorta;
    private javax.swing.JTextField jtf_existencia;
    private javax.swing.JTextField jtf_factor;
    private javax.swing.JTextField jtf_fechaprototipo;
    private javax.swing.JTextField jtf_fechaultcompra;
    private javax.swing.JTextField jtf_idarticuloterminado;
    private javax.swing.JTextField jtf_idinsumo;
    private javax.swing.JTextField jtf_idproveedor;
    private javax.swing.JTextField jtf_importecostohoja;
    private javax.swing.JTextField jtf_importeimplosion;
    private javax.swing.JTextField jtf_inicioproduccion;
    private javax.swing.JTextField jtf_item;
    private javax.swing.JTextField jtf_lugaralmacen;
    private javax.swing.JTextField jtf_nombrecreador;
    private javax.swing.JTextField jtf_pendientesurtir;
    private javax.swing.JTextField jtf_piezastotal;
    private javax.swing.JTextField jtf_precio1;
    private javax.swing.JTextField jtf_precio2;
    private javax.swing.JTextField jtf_precio3;
    private javax.swing.JTextField jtf_precio4;
    private javax.swing.JTextField jtf_precio5;
    private javax.swing.JTextField jtf_proveedordescribe;
    private javax.swing.JTextField jtf_stockmaximo;
    private javax.swing.JTextField jtf_stockminimo;
    private javax.swing.JTextField jtf_terminadasimplosion;
    private javax.swing.JTextField jtf_tiemporsurtido;
    private javax.swing.JTextField jtf_ultimocosto;
    private javax.swing.JTextField jtf_unidadempake;
    private javax.swing.JTextField jtf_unidadentrada;
    private javax.swing.JTextField jtf_unidadsalida;
    // End of variables declaration//GEN-END:variables

}
